osdefs.h 737 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. #ifndef Py_OSDEFS_H
  2. #define Py_OSDEFS_H
  3. #ifdef __cplusplus
  4. extern "C" {
  5. #endif
  6. /* Operating system dependencies */
  7. #ifdef MS_WINDOWS
  8. #define SEP L'\\'
  9. #define ALTSEP L'/'
  10. #define MAXPATHLEN 256
  11. #define DELIM L';'
  12. #endif
  13. #ifdef __VXWORKS__
  14. #define DELIM L';'
  15. #endif
  16. /* Filename separator */
  17. #ifndef SEP
  18. #define SEP L'/'
  19. #endif
  20. /* Max pathname length */
  21. #ifdef __hpux
  22. #include <sys/param.h>
  23. #include <limits.h>
  24. #ifndef PATH_MAX
  25. #define PATH_MAX MAXPATHLEN
  26. #endif
  27. #endif
  28. #ifndef MAXPATHLEN
  29. #if defined(PATH_MAX) && PATH_MAX > 1024
  30. #define MAXPATHLEN PATH_MAX
  31. #else
  32. #define MAXPATHLEN 1024
  33. #endif
  34. #endif
  35. /* Search path entry delimiter */
  36. #ifndef DELIM
  37. #define DELIM L':'
  38. #endif
  39. #ifdef __cplusplus
  40. }
  41. #endif
  42. #endif /* !Py_OSDEFS_H */