select_platform_config.hpp 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143
  1. // Boost compiler configuration selection header file
  2. // (C) Copyright John Maddock 2001 - 2002.
  3. // (C) Copyright Jens Maurer 2001.
  4. // Use, modification and distribution are subject to the
  5. // Boost Software License, Version 1.0. (See accompanying file
  6. // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
  7. // See http://www.boost.org for most recent version.
  8. // locate which platform we are on and define BOOST_PLATFORM_CONFIG as needed.
  9. // Note that we define the headers to include using "header_name" not
  10. // <header_name> in order to prevent macro expansion within the header
  11. // name (for example "linux" is a macro on linux systems).
  12. #if (defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)) && !defined(_CRAYC)
  13. // linux, also other platforms (Hurd etc) that use GLIBC, should these really have their own config headers though?
  14. # define BOOST_PLATFORM_CONFIG "boost/config/platform/linux.hpp"
  15. #elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
  16. // BSD:
  17. # define BOOST_PLATFORM_CONFIG "boost/config/platform/bsd.hpp"
  18. #elif defined(sun) || defined(__sun)
  19. // solaris:
  20. # define BOOST_PLATFORM_CONFIG "boost/config/platform/solaris.hpp"
  21. #elif defined(__sgi)
  22. // SGI Irix:
  23. # define BOOST_PLATFORM_CONFIG "boost/config/platform/irix.hpp"
  24. #elif defined(__hpux)
  25. // hp unix:
  26. # define BOOST_PLATFORM_CONFIG "boost/config/platform/hpux.hpp"
  27. #elif defined(__CYGWIN__)
  28. // cygwin is not win32:
  29. # define BOOST_PLATFORM_CONFIG "boost/config/platform/cygwin.hpp"
  30. #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
  31. // win32:
  32. # define BOOST_PLATFORM_CONFIG "boost/config/platform/win32.hpp"
  33. #elif defined(__HAIKU__)
  34. // Haiku
  35. # define BOOST_PLATFORM_CONFIG "boost/config/platform/haiku.hpp"
  36. #elif defined(__BEOS__)
  37. // BeOS
  38. # define BOOST_PLATFORM_CONFIG "boost/config/platform/beos.hpp"
  39. #elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)
  40. // MacOS
  41. # define BOOST_PLATFORM_CONFIG "boost/config/platform/macos.hpp"
  42. #elif defined(__TOS_MVS__)
  43. // IBM z/OS
  44. # define BOOST_PLATFORM_CONFIG "boost/config/platform/zos.hpp"
  45. #elif defined(__IBMCPP__) || defined(_AIX)
  46. // IBM AIX
  47. # define BOOST_PLATFORM_CONFIG "boost/config/platform/aix.hpp"
  48. #elif defined(__amigaos__)
  49. // AmigaOS
  50. # define BOOST_PLATFORM_CONFIG "boost/config/platform/amigaos.hpp"
  51. #elif defined(__QNXNTO__)
  52. // QNX:
  53. # define BOOST_PLATFORM_CONFIG "boost/config/platform/qnxnto.hpp"
  54. #elif defined(__VXWORKS__)
  55. // vxWorks:
  56. # define BOOST_PLATFORM_CONFIG "boost/config/platform/vxworks.hpp"
  57. #elif defined(__SYMBIAN32__)
  58. // Symbian:
  59. # define BOOST_PLATFORM_CONFIG "boost/config/platform/symbian.hpp"
  60. #elif defined(_CRAYC)
  61. // Cray:
  62. # define BOOST_PLATFORM_CONFIG "boost/config/platform/cray.hpp"
  63. #elif defined(__VMS)
  64. // VMS:
  65. # define BOOST_PLATFORM_CONFIG "boost/config/platform/vms.hpp"
  66. #elif defined(__CloudABI__)
  67. // Nuxi CloudABI:
  68. # define BOOST_PLATFORM_CONFIG "boost/config/platform/cloudabi.hpp"
  69. #else
  70. # if defined(unix) \
  71. || defined(__unix) \
  72. || defined(_XOPEN_SOURCE) \
  73. || defined(_POSIX_SOURCE)
  74. // generic unix platform:
  75. # ifndef BOOST_HAS_UNISTD_H
  76. # define BOOST_HAS_UNISTD_H
  77. # endif
  78. # include <boost/config/detail/posix_features.hpp>
  79. # endif
  80. # if defined (BOOST_ASSERT_CONFIG)
  81. // this must come last - generate an error if we don't
  82. // recognise the platform:
  83. # error "Unknown platform - please configure and report the results to boost.org"
  84. # endif
  85. #endif
  86. #if 0
  87. //
  88. // This section allows dependency scanners to find all the files we *might* include:
  89. //
  90. # include "boost/config/platform/linux.hpp"
  91. # include "boost/config/platform/bsd.hpp"
  92. # include "boost/config/platform/solaris.hpp"
  93. # include "boost/config/platform/irix.hpp"
  94. # include "boost/config/platform/hpux.hpp"
  95. # include "boost/config/platform/cygwin.hpp"
  96. # include "boost/config/platform/win32.hpp"
  97. # include "boost/config/platform/beos.hpp"
  98. # include "boost/config/platform/macos.hpp"
  99. # include "boost/config/platform/zos.hpp"
  100. # include "boost/config/platform/aix.hpp"
  101. # include "boost/config/platform/amigaos.hpp"
  102. # include "boost/config/platform/qnxnto.hpp"
  103. # include "boost/config/platform/vxworks.hpp"
  104. # include "boost/config/platform/symbian.hpp"
  105. # include "boost/config/platform/cray.hpp"
  106. # include "boost/config/platform/vms.hpp"
  107. # include <boost/config/detail/posix_features.hpp>
  108. #endif