summaryrefslogtreecommitdiff
path: root/src/faketime_common.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/faketime_common.h')
-rw-r--r--src/faketime_common.h24
1 files changed, 24 insertions, 0 deletions
diff --git a/src/faketime_common.h b/src/faketime_common.h
index 9fda6a7..c95f69f 100644
--- a/src/faketime_common.h
+++ b/src/faketime_common.h
@@ -58,4 +58,28 @@ struct ft_shared_s
#include <mach/mach_port.h>
#endif
+#ifdef FAKE_SLEEP
+#include <time.h>
+#include <poll.h>
+#include <sys/types.h>
+#include <semaphore.h>
+/*
+ * Fake sleep prototypes!
+ */
+struct pollfd;
+
+int nanosleep(const struct timespec *req, struct timespec *rem);
+int usleep(useconds_t usec);
+unsigned int sleep(unsigned int seconds);
+unsigned int alarm(unsigned int seconds);
+int ppoll(struct pollfd *fds, nfds_t nfds,
+const struct timespec *timeout_ts, const sigset_t *sigmask);
+int poll(struct pollfd *fds, nfds_t nfds, int timeout);
+int select(int nfds, fd_set *readfds,
+ fd_set *writefds,
+ fd_set *errorfds,
+ struct timeval *timeout);
+int sem_timedwait(sem_t *sem, const struct timespec *abs_timeout);
+#endif /* FAKE_SLEEP */
+
#endif