Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: downloads/boost_1_34_1/boost/thread/detail/config.hpp @ 29

Last change on this file since 29 was 29, checked in by landauf, 17 years ago

updated boost from 1_33_1 to 1_34_1

File size: 3.0 KB
Line 
1// Copyright (C) 2001-2003
2// William E. Kempf
3//
4//  Distributed under the Boost Software License, Version 1.0. (See accompanying
5//  file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
6
7#ifndef BOOST_THREAD_CONFIG_WEK01032003_HPP
8#define BOOST_THREAD_CONFIG_WEK01032003_HPP
9
10#include <boost/config.hpp>
11#include <boost/detail/workaround.hpp>
12
13#if BOOST_WORKAROUND(__BORLANDC__, < 0x600)
14#  pragma warn -8008 // Condition always true/false
15#  pragma warn -8080 // Identifier declared but never used
16#  pragma warn -8057 // Parameter never used
17#  pragma warn -8066 // Unreachable code
18#endif
19
20// insist on threading support being available:
21#include <boost/config/requires_threads.hpp>
22
23// compatibility with the rest of Boost's auto-linking code:
24#if defined(BOOST_THREAD_DYN_DLL) || defined(BOOST_ALL_DYN_LINK)
25# undef  BOOST_THREAD_USE_LIB
26# define BOOST_THREAD_USE_DLL
27#endif
28
29#if defined(BOOST_THREAD_BUILD_DLL)   //Build dll
30#elif defined(BOOST_THREAD_BUILD_LIB) //Build lib
31#elif defined(BOOST_THREAD_USE_DLL)   //Use dll
32#elif defined(BOOST_THREAD_USE_LIB)   //Use lib
33#else //Use default
34#   if defined(BOOST_HAS_WINTHREADS)
35#       if defined(BOOST_MSVC) || defined(BOOST_INTEL_WIN)
36            //For compilers supporting auto-tss cleanup
37            //with Boost.Threads lib, use Boost.Threads lib
38#           define BOOST_THREAD_USE_LIB
39#       else
40            //For compilers not yet supporting auto-tss cleanup
41            //with Boost.Threads lib, use Boost.Threads dll
42#           define BOOST_THREAD_USE_DLL
43#       endif
44#   else
45#       define BOOST_THREAD_USE_LIB
46#   endif
47#endif
48
49#if defined(BOOST_HAS_DECLSPEC)
50#   if defined(BOOST_THREAD_BUILD_DLL) //Build dll
51#       define BOOST_THREAD_DECL __declspec(dllexport)
52#   elif defined(BOOST_THREAD_USE_DLL) //Use dll
53#       define BOOST_THREAD_DECL __declspec(dllimport)
54#   else
55#       define BOOST_THREAD_DECL
56#   endif
57#else
58#   define BOOST_THREAD_DECL
59#endif // BOOST_HAS_DECLSPEC
60
61//
62// Automatically link to the correct build variant where possible.
63//
64#if !defined(BOOST_ALL_NO_LIB) && !defined(BOOST_THREAD_NO_LIB) && !defined(BOOST_THREAD_BUILD_DLL) && !defined(BOOST_THREAD_BUILD_LIB)
65//
66// Tell the autolink to link dynamically, this will get undef'ed by auto_link.hpp
67// once it's done with it:
68//
69#if defined(BOOST_THREAD_USE_DLL)
70#   define BOOST_DYN_LINK
71#endif
72//
73// Set the name of our library, this will get undef'ed by auto_link.hpp
74// once it's done with it:
75//
76#if defined(BOOST_THREAD_LIB_NAME)
77#    define BOOST_LIB_NAME BOOST_THREAD_LIB_NAME
78#else
79#    define BOOST_LIB_NAME boost_thread
80#endif
81//
82// If we're importing code from a dll, then tell auto_link.hpp about it:
83//
84// And include the header that does the work:
85//
86#include <boost/config/auto_link.hpp>
87#endif  // auto-linking disabled
88
89#endif // BOOST_THREAD_CONFIG_WEK1032003_HPP
90
91// Change Log:
92//   22 Jan 05 Roland Schwarz (speedsnail)
93//      Usage of BOOST_HAS_DECLSPEC macro.
94//      Default again is static lib usage.
95//      BOOST_DYN_LINK only defined when autolink included.
Note: See TracBrowser for help on using the repository browser.