_tbb_windef.h

00001 /*
00002     Copyright 2005-2009 Intel Corporation.  All Rights Reserved.
00003 
00004     The source code contained or described herein and all documents related
00005     to the source code ("Material") are owned by Intel Corporation or its
00006     suppliers or licensors.  Title to the Material remains with Intel
00007     Corporation or its suppliers and licensors.  The Material is protected
00008     by worldwide copyright laws and treaty provisions.  No part of the
00009     Material may be used, copied, reproduced, modified, published, uploaded,
00010     posted, transmitted, distributed, or disclosed in any way without
00011     Intel's prior express written permission.
00012 
00013     No license under any patent, copyright, trade secret or other
00014     intellectual property right is granted to or conferred upon you by
00015     disclosure or delivery of the Materials, either expressly, by
00016     implication, inducement, estoppel or otherwise.  Any license under such
00017     intellectual property rights must be express and approved by Intel in
00018     writing.
00019 */
00020 
00021 #ifndef __TBB_tbb_windef_H
00022 #error Do not #include this file directly.  Use "#include tbb/tbb_stddef.h" instead.
00023 #endif /* __TBB_tbb_windef_H */
00024 
00025 // Check that the target Windows version has all API calls requried for TBB.
00026 // Do not increase the version in condition beyond 0x0500 without prior discussion!
00027 #if defined(_WIN32_WINNT) && _WIN32_WINNT<0x0400
00028 #error TBB is unable to run on old Windows versions; _WIN32_WINNT must be 0x0400 or greater.
00029 #endif
00030 
00031 #if !defined(_MT)
00032 #error TBB requires linkage with multithreaded C/C++ runtime library. \
00033        Choose multithreaded DLL runtime in project settings, or use /MD[d] compiler switch.
00034 #elif !defined(_DLL)
00035 #pragma message("Warning: Using TBB together with static C/C++ runtime library is not recommended. " \
00036                 "Consider switching your project to multithreaded DLL runtime used by TBB.")
00037 #endif
00038 
00039 // Workaround for the problem with MVSC headers failing to define namespace std
00040 namespace std {
00041   using ::size_t; using ::ptrdiff_t;
00042 }
00043 
00044 #define __TBB_STRING_AUX(x) #x
00045 #define __TBB_STRING(x) __TBB_STRING_AUX(x)
00046 
00047 // Default setting of TBB_USE_DEBUG
00048 #ifdef TBB_USE_DEBUG
00049 #    if TBB_USE_DEBUG 
00050 #        if !defined(_DEBUG)
00051 #            pragma message(__FILE__ "(" __TBB_STRING(__LINE__) ") : Warning: Recommend using /MDd if compiling with TBB_USE_DEBUG!=0")
00052 #        endif
00053 #    else
00054 #        if defined(_DEBUG)
00055 #            pragma message(__FILE__ "(" __TBB_STRING(__LINE__) ") : Warning: Recommend using /MD if compiling with TBB_USE_DEBUG==0")
00056 #        endif
00057 #    endif
00058 #else
00059 #    ifdef _DEBUG
00060 #        define TBB_USE_DEBUG 1
00061 #    endif
00062 #endif 
00063 
00064 #if __TBB_BUILD && !defined(__TBB_NO_IMPLICIT_LINKAGE)
00065 #define __TBB_NO_IMPLICIT_LINKAGE 1
00066 #endif
00067 
00068 #if _MSC_VER
00069     #if !__TBB_NO_IMPLICIT_LINKAGE
00070         #ifdef _DEBUG
00071             #pragma comment(lib, "tbb_debug.lib")
00072         #else
00073             #pragma comment(lib, "tbb.lib")
00074         #endif
00075     #endif
00076 #endif

Copyright © 2005-2009 Intel Corporation. All Rights Reserved.

Intel, Pentium, Intel Xeon, Itanium, Intel XScale and VTune are registered trademarks or trademarks of Intel Corporation or its subsidiaries in the United States and other countries.

* Other names and brands may be claimed as the property of others.