]> git.lyx.org Git - lyx.git/blob - boost/boost/config/requires_threads.hpp
update to boost 1.39: add new files
[lyx.git] / boost / boost / config / requires_threads.hpp
1 //  (C) Copyright John Maddock 2003. \r
2 //  Use, modification and distribution are subject to the \r
3 //  Boost Software License, Version 1.0. (See accompanying file \r
4 //  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)\r
5 \r
6 \r
7 #ifndef BOOST_CONFIG_REQUIRES_THREADS_HPP\r
8 #define BOOST_CONFIG_REQUIRES_THREADS_HPP\r
9 \r
10 #ifndef BOOST_CONFIG_HPP\r
11 #  include <boost/config.hpp>\r
12 #endif\r
13 \r
14 #if defined(BOOST_DISABLE_THREADS)\r
15 \r
16 //\r
17 // special case to handle versions of gcc which don't currently support threads:\r
18 //\r
19 #if defined(__GNUC__) && ((__GNUC__ < 3) || (__GNUC_MINOR__ <= 3) || !defined(BOOST_STRICT_CONFIG))\r
20 //\r
21 // this is checked up to gcc 3.3:\r
22 //\r
23 #if defined(__sgi) || defined(__hpux)\r
24 #  error "Multi-threaded programs are not supported by gcc on HPUX or Irix (last checked with gcc 3.3)"\r
25 #endif\r
26 \r
27 #endif\r
28 \r
29 #  error "Threading support unavaliable: it has been explicitly disabled with BOOST_DISABLE_THREADS"\r
30 \r
31 #elif !defined(BOOST_HAS_THREADS)\r
32 \r
33 # if defined __COMO__\r
34 //  Comeau C++\r
35 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_MT (Windows) or -D_REENTRANT (Unix)"\r
36 \r
37 #elif defined(__INTEL_COMPILER) || defined(__ICL) || defined(__ICC) || defined(__ECC)\r
38 //  Intel\r
39 #ifdef _WIN32\r
40 #  error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd"\r
41 #else\r
42 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -openmp"\r
43 #endif\r
44 \r
45 # elif defined __GNUC__\r
46 //  GNU C++:\r
47 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread (Linux), -pthreads (Solaris) or -mthreads (Mingw32)"\r
48 \r
49 #elif defined __sgi\r
50 //  SGI MIPSpro C++\r
51 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -D_SGI_MP_SOURCE"\r
52 \r
53 #elif defined __DECCXX\r
54 //  Compaq Tru64 Unix cxx\r
55 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -pthread"\r
56 \r
57 #elif defined __BORLANDC__\r
58 //  Borland\r
59 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -tWM"\r
60 \r
61 #elif defined  __MWERKS__\r
62 //  Metrowerks CodeWarrior\r
63 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: either -runtime sm, -runtime smd, -runtime dm, or -runtime dmd"\r
64 \r
65 #elif defined  __SUNPRO_CC\r
66 //  Sun Workshop Compiler C++\r
67 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt"\r
68 \r
69 #elif defined __HP_aCC\r
70 //  HP aCC\r
71 #   error "Compiler threading support is not turned on. Please set the correct command line options for threading: -mt"\r
72 \r
73 #elif defined(__IBMCPP__)\r
74 //  IBM Visual Age\r
75 #   error "Compiler threading support is not turned on. Please compile the code with the xlC_r compiler"\r
76 \r
77 #elif defined _MSC_VER\r
78 //  Microsoft Visual C++\r
79 //\r
80 //  Must remain the last #elif since some other vendors (Metrowerks, for\r
81 //  example) also #define _MSC_VER\r
82 #  error "Compiler threading support is not turned on. Please set the correct command line options for threading: either /MT /MTd /MD or /MDd"\r
83 \r
84 #else\r
85 \r
86 #  error "Compiler threading support is not turned on.  Please consult your compiler's documentation for the appropriate options to use"\r
87 \r
88 #endif // compilers\r
89 \r
90 #endif // BOOST_HAS_THREADS\r
91 \r
92 #endif // BOOST_CONFIG_REQUIRES_THREADS_HPP\r