compat.h 487 B

123456789101112131415161718192021222324252627282930313233
  1. #ifndef __COMPAT_H__
  2. #define __COMPAT_H__
  3. #ifndef __SUSECONDS_T_TYPE
  4. typedef long suseconds_t;
  5. #endif
  6. #ifdef WIN32
  7. #include <windows.h>
  8. static inline void sleep(int secs)
  9. {
  10. Sleep(secs * 1000);
  11. }
  12. enum {
  13. PRIO_PROCESS = 0,
  14. };
  15. static inline int setpriority(int which, int who, int prio)
  16. {
  17. /* FIXME - actually do something */
  18. return 0;
  19. }
  20. typedef unsigned long int ulong;
  21. typedef unsigned short int ushort;
  22. typedef unsigned int uint;
  23. #endif /* WIN32 */
  24. #endif /* __COMPAT_H__ */