config.h.bot 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. /* These are from config.h.bot, pasted onto the end of config.h.in. */
  2. #ifdef HAVE_SYS_CDEFS_H
  3. #include <sys/cdefs.h>
  4. #endif
  5. /* Use the definitions: */
  6. /* Give us an unsigned 32-bit data type. */
  7. #if SIZEOF_UNSIGNED_LONG==4
  8. #define UWORD32 unsigned long
  9. #elif SIZEOF_UNSIGNED_INT==4
  10. #define UWORD32 unsigned int
  11. #else
  12. #error I do not know what to use for a UWORD32.
  13. #endif
  14. /* The maximum length of a #! interpreter displayed by dpkg-deb. */
  15. #ifdef PATH_MAX
  16. #define INTERPRETER_MAX PATH_MAX
  17. #else
  18. #define INTERPRETER_MAX 1024
  19. #endif
  20. /* GNU C attributes. */
  21. #ifndef FUNCATTR
  22. #ifdef HAVE_GNUC25_ATTRIB
  23. #define FUNCATTR(x) __attribute__(x)
  24. #else
  25. #define FUNCATTR(x)
  26. #endif
  27. #endif
  28. /* GNU C printf formats, or null. */
  29. #ifndef ATTRPRINTF
  30. #ifdef HAVE_GNUC25_PRINTFFORMAT
  31. #define ATTRPRINTF(si,tc) format(printf,si,tc)
  32. #else
  33. #define ATTRPRINTF(si,tc)
  34. #endif
  35. #endif
  36. #ifndef PRINTFFORMAT
  37. #define PRINTFFORMAT(si,tc) FUNCATTR((ATTRPRINTF(si,tc)))
  38. #endif
  39. /* GNU C nonreturning functions, or null. */
  40. #ifndef ATTRNORETURN
  41. #ifdef HAVE_GNUC25_NORETURN
  42. #define ATTRNORETURN noreturn
  43. #else
  44. #define ATTRNORETURN
  45. #endif
  46. #endif
  47. #ifndef NONRETURNING
  48. #define NONRETURNING FUNCATTR((ATTRNORETURN))
  49. #endif
  50. /* Combination of both the above. */
  51. #ifndef NONRETURNPRINTFFORMAT
  52. #define NONRETURNPRINTFFORMAT(si,tc) FUNCATTR((ATTRPRINTF(si,tc),ATTRNORETURN))
  53. #endif
  54. /* GNU C constant functions, or null. */
  55. #ifndef ATTRCONST
  56. #ifdef HAVE_GNUC25_CONST
  57. #define ATTRCONST const
  58. #else
  59. #define ATTRCONST
  60. #endif
  61. #endif
  62. #ifndef CONSTANT
  63. #define CONSTANT FUNCATTR((ATTRCONST))
  64. #endif
  65. /* Declare strerror if we don't have it already. */
  66. #ifndef HAVE_STRERROR
  67. const char *strerror(int);
  68. #endif
  69. /* Declare strsignal if we don't have it already. */
  70. #ifndef HAVE_STRSIGNAL
  71. const char *strsignal(int);
  72. #endif
  73. /* Declare scandir if we don't have it already. */
  74. #ifndef HAVE_SCANDIR
  75. struct dirent;
  76. int scandir(const char *dir, struct dirent ***namelist,
  77. int (*select)(const struct dirent *),
  78. int (*compar)(const void*, const void*));
  79. #endif
  80. /* Declare alphasort if we don't have it already. */
  81. #if !defined(HAVE_ALPHASORT) || !defined(HAVE_ALPHASORT_DECLARATION)
  82. struct dirent;
  83. int alphasort(const struct dirent *a, const struct dirent *b);
  84. #endif
  85. /* Declare unsetenv if we don't have it already. */
  86. #ifndef HAVE_UNSETENV
  87. void unsetenv(const char *x);
  88. #endif
  89. /* Define strtoul if we don't have it already. */
  90. #ifndef HAVE_STRTOUL
  91. #define strtoul strtol
  92. #endif
  93. /* Sort out sysinfo */
  94. #if !defined(HAVE_SYSINFO) && defined(HAVE_NRSYSINFO)
  95. #include <linux/sys.h>
  96. #include <linux/kernel.h>
  97. #include <linux/unistd.h>
  98. static inline _syscall1(int,sysinfo,struct sysinfo*,info)
  99. #endif
  100. /* Define WCOREDUMP if we don't have it already - coredumps won't be
  101. * detected, though.
  102. */
  103. #ifndef WCOREDUMP
  104. #define WCOREDUMP(x) 0
  105. #endif
  106. /* Set BUILDOLDPKGFORMAT to 1 to build old-format archives by default.
  107. */
  108. #ifndef BUILDOLDPKGFORMAT
  109. #define BUILDOLDPKGFORMAT 0
  110. #endif