File: select_platform_config.hpp

package info (click to toggle)
gecode-snapshot 6.2.0%2Bgit20240207-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 35,308 kB
  • sloc: cpp: 475,516; perl: 2,077; makefile: 1,816; sh: 198
file content (101 lines) | stat: -rw-r--r-- 3,531 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
//  Boost compiler configuration selection header file

//  (C) Copyright John Maddock 2001 - 2002.
//  (C) Copyright Jens Maurer 2001.
//  Use, modification and distribution are subject to the
//  Boost Software License, Version 1.0. (See accompanying file
//  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)

//  See http://www.boost.org for most recent version.

// locate which platform we are on and define GECODE_BOOST_PLATFORM_CONFIG as needed.
// Note that we define the headers to include using "header_name" not
// <header_name> in order to prevent macro expansion within the header
// name (for example "linux" is a macro on linux systems).

#if defined(linux) || defined(__linux) || defined(__linux__) || defined(__GNU__) || defined(__GLIBC__)
// linux, also other platforms (Hurd etc) that use GLIBC, should these really have their own config headers though?
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/linux.hpp"

#elif defined(__FreeBSD__) || defined(__NetBSD__) || defined(__OpenBSD__) || defined(__DragonFly__)
// BSD:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/bsd.hpp"

#elif defined(sun) || defined(__sun)
// solaris:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/solaris.hpp"

#elif defined(__sgi)
// SGI Irix:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/irix.hpp"

#elif defined(__hpux)
// hp unix:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/hpux.hpp"

#elif defined(__CYGWIN__)
// cygwin is not win32:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/cygwin.hpp"

#elif defined(_WIN32) || defined(__WIN32__) || defined(WIN32)
// win32:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/win32.hpp"

#elif defined(__BEOS__)
// BeOS
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/beos.hpp"

#elif defined(macintosh) || defined(__APPLE__) || defined(__APPLE_CC__)
// MacOS
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/macos.hpp"

#elif defined(__IBMCPP__) || defined(_AIX)
// IBM
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/aix.hpp"

#elif defined(__amigaos__)
// AmigaOS
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/amigaos.hpp"

#elif defined(__QNXNTO__)
// QNX:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/qnxnto.hpp"

#elif defined(__VXWORKS__)
// vxWorks:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/vxworks.hpp"

#elif defined(__SYMBIAN32__)
// Symbian:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/symbian.hpp"

#elif defined(__VMS)
// VMS:
#  define GECODE_BOOST_PLATFORM_CONFIG "gecode/third-party/boost/config/platform/vms.hpp"
#else

#  if defined(unix) \
      || defined(__unix) \
      || defined(_XOPEN_SOURCE) \
      || defined(_POSIX_SOURCE)

   // generic unix platform:

#  ifndef GECODE_BOOST_HAS_UNISTD_H
#     define GECODE_BOOST_HAS_UNISTD_H
#  endif

#  include <gecode/third-party/boost/config/posix_features.hpp>

#  endif

#  if defined (GECODE_BOOST_ASSERT_CONFIG)
      // this must come last - generate an error if we don't
      // recognise the platform:
#     error "Unknown platform - please configure and report the results to boost.org"
#  endif

#endif