1 // Boost compiler configuration selection header file
3 // (C) Copyright John Maddock 2001 - 2002.
4 // (C) Copyright Jens Maurer 2001.
5 // Use, modification and distribution are subject to the
6 // Boost Software License, Version 1.0. (See accompanying file
7 // LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
9 // See http://www.boost.org for most recent version.
11 // locate which platform we are on and define BOOST_PLATFORM_CONFIG as needed.
12 // Note that we define the headers to include using "header_name" not
13 // <header_name> in order to prevent macro expansion within the header
14 // name (for example "linux" is a macro on linux systems).
16 #if defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
17 // linux, also other platforms (Hurd etc) that use GLIBC, should these really have their own config headers though?
18 # define BOOST_PLATFORM_CONFIG "boost/config/platform/linux.hpp"
20 #elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
22 # define BOOST_PLATFORM_CONFIG "boost/config/platform/bsd.hpp"
24 #elif defined(sun) || defined(__sun)
26 # define BOOST_PLATFORM_CONFIG "boost/config/platform/solaris.hpp"
30 # define BOOST_PLATFORM_CONFIG "boost/config/platform/irix.hpp"
34 # define BOOST_PLATFORM_CONFIG "boost/config/platform/hpux.hpp"
36 #elif defined(__CYGWIN__)
37 // cygwin is not win32:
38 # define BOOST_PLATFORM_CONFIG "boost/config/platform/cygwin.hpp"
40 #elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
42 # define BOOST_PLATFORM_CONFIG "boost/config/platform/win32.hpp"
44 #elif defined(__BEOS__)
46 # define BOOST_PLATFORM_CONFIG "boost/config/platform/beos.hpp"
48 #elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)
50 # define BOOST_PLATFORM_CONFIG "boost/config/platform/macos.hpp"
52 #elif defined(__IBMCPP__) || defined(_AIX)
54 # define BOOST_PLATFORM_CONFIG "boost/config/platform/aix.hpp"
56 #elif defined(__amigaos__)
58 # define BOOST_PLATFORM_CONFIG "boost/config/platform/amigaos.hpp"
60 #elif defined(__QNXNTO__)
62 # define BOOST_PLATFORM_CONFIG "boost/config/platform/qnxnto.hpp"
64 #elif defined(__VXWORKS__)
66 # define BOOST_PLATFORM_CONFIG "boost/config/platform/vxworks.hpp"
72 || defined(_XOPEN_SOURCE) \
73 || defined(_POSIX_SOURCE)
75 // generic unix platform:
77 # ifndef BOOST_HAS_UNISTD_H
78 # define BOOST_HAS_UNISTD_H
81 # include <boost/config/posix_features.hpp>
85 # if defined (BOOST_ASSERT_CONFIG)
86 // this must come last - generate an error if we don't
87 // recognise the platform:
88 # error "Unknown platform - please configure and report the results to boost.org"