BWAPI
|
00001 // Copyright (c) 1997-2004 Utrecht University (The Netherlands), 00002 // ETH Zurich (Switzerland), Freie Universitaet Berlin (Germany), 00003 // INRIA Sophia-Antipolis (France), Martin-Luther-University Halle-Wittenberg 00004 // (Germany), Max-Planck-Institute Saarbruecken (Germany), RISC Linz (Austria), 00005 // and Tel-Aviv University (Israel). All rights reserved. 00006 // 00007 // This file is part of CGAL (www.cgal.org); you can redistribute it and/or 00008 // modify it under the terms of the GNU Lesser General Public License as 00009 // published by the Free Software Foundation; version 2.1 of the License. 00010 // See the file LICENSE.LGPL distributed with CGAL. 00011 // 00012 // Licensees holding a valid commercial license may use this file in 00013 // accordance with the commercial license agreement provided with the software. 00014 // 00015 // This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 00016 // WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 00017 // 00018 // $URL: svn+ssh://scm.gforge.inria.fr/svn/cgal/branches/CGAL-3.5-branch/Installation/include/CGAL/config.h $ 00019 // $Id: config.h 49591 2009-05-26 08:18:11Z spion $ 00020 // 00021 // 00022 // Author(s) : Wieger Wesselink 00023 // Michael Hoffmann <hoffmann@inf.ethz.ch> 00024 // Sylvain Pion 00025 00026 #ifndef CGAL_CONFIG_H 00027 #define CGAL_CONFIG_H 00028 00029 00030 #ifdef CGAL_INCLUDE_WINDOWS_DOT_H 00031 // Mimic users including this file which defines min max macros 00032 // and other names leading to name clashes 00033 #include <windows.h> 00034 #endif 00035 00036 // The following header file defines among other things BOOST_PREVENT_MACRO_SUBSTITUTION 00037 #include <boost/config.hpp> 00038 00039 #include <CGAL/version.h> 00040 00041 //----------------------------------------------------------------------// 00042 // include platform specific workaround flags (CGAL_CFG_...) 00043 //----------------------------------------------------------------------// 00044 00045 #include <CGAL/compiler_config.h> 00046 00047 //----------------------------------------------------------------------// 00048 // auto-link the CGAL library on platforms that support it 00049 //----------------------------------------------------------------------// 00050 #include <CGAL/auto_link/CGAL.h> 00051 00052 //----------------------------------------------------------------------// 00053 // do some post processing for the flags 00054 //----------------------------------------------------------------------// 00055 00056 #ifdef CGAL_CFG_NO_STL 00057 # error "This compiler does not have a working STL" 00058 #endif 00059 00060 // This macro computes the version number from an x.y.z release number. 00061 // It only works for public releases. 00062 #define CGAL_VERSION_NUMBER(x,y,z) (1000001 + 10000*x + 100*y + 10*z) * 1000 00063 00064 #define CGAL_BEGIN_NAMESPACE namespace CGAL { 00065 #define CGAL_END_NAMESPACE } 00066 00067 #ifndef CGAL_CFG_NO_CPP0X_LONG_LONG 00068 # define CGAL_USE_LONG_LONG 00069 #endif 00070 00071 00072 #ifndef CGAL_CFG_TYPENAME_BEFORE_DEFAULT_ARGUMENT_BUG 00073 # define CGAL_TYPENAME_DEFAULT_ARG typename 00074 #else 00075 # define CGAL_TYPENAME_DEFAULT_ARG 00076 #endif 00077 00078 00079 #ifdef CGAL_CFG_NO_CPP0X_DELETED_AND_DEFAULT_FUNCTIONS 00080 # define CGAL_DELETED 00081 # define CGAL_EXPLICITLY_DEFAULTED 00082 #else 00083 # define CGAL_DELETED = delete 00084 # define CGAL_EXPLICITLY_DEFAULTED = default 00085 #endif 00086 00087 00088 // Big endian or little endian machine. 00089 // ==================================== 00090 00091 #if defined (__GLIBC__) 00092 # include <endian.h> 00093 # if (__BYTE_ORDER == __LITTLE_ENDIAN) 00094 # define CGAL_LITTLE_ENDIAN 00095 # elif (__BYTE_ORDER == __BIG_ENDIAN) 00096 # define CGAL_BIG_ENDIAN 00097 # else 00098 # error Unknown endianness 00099 # endif 00100 #elif defined(__sparc) || defined(__sparc__) \ 00101 || defined(_POWER) || defined(__powerpc__) \ 00102 || defined(__ppc__) || defined(__hppa) \ 00103 || defined(_MIPSEB) || defined(_POWER) \ 00104 || defined(__s390__) 00105 # define CGAL_BIG_ENDIAN 00106 #elif defined(__i386__) || defined(__alpha__) \ 00107 || defined(__x86_64) || defined(__x86_64__) \ 00108 || defined(__ia64) || defined(__ia64__) \ 00109 || defined(_M_IX86) || defined(_M_IA64) \ 00110 || defined(_M_ALPHA) || defined(_WIN64) 00111 # define CGAL_LITTLE_ENDIAN 00112 #else 00113 # error Unknown endianness 00114 #endif 00115 00116 00117 // Symbolic constants to tailor inlining. Inlining Policy. 00118 // ======================================================= 00119 #ifndef CGAL_MEDIUM_INLINE 00120 # define CGAL_MEDIUM_INLINE inline 00121 #endif 00122 00123 #ifndef CGAL_LARGE_INLINE 00124 # define CGAL_LARGE_INLINE 00125 #endif 00126 00127 #ifndef CGAL_HUGE_INLINE 00128 # define CGAL_HUGE_INLINE 00129 #endif 00130 00131 00132 //----------------------------------------------------------------------// 00133 // SunPRO specific. 00134 //----------------------------------------------------------------------// 00135 #ifdef __SUNPRO_CC 00136 # include <iterator> 00137 # ifdef _RWSTD_NO_CLASS_PARTIAL_SPEC 00138 # warning "CGAL does not support SunPRO with the old Rogue Wave STL: use STLPort." 00139 # endif 00140 00141 // Sun CC has an issue with templates that means overloading 00142 // Qualified_result_of does not work so well. 00143 # define CGAL_CFG_DONT_OVERLOAD_TOO_MUCH 1 00144 00145 #endif 00146 00147 #ifdef __SUNPRO_CC 00148 // SunPRO 5.9 emits warnings "The variable tag has not yet been assigned a value" 00149 // even for empty "tag" variables. No way to write a config/testfile for this. 00150 # define CGAL_SUNPRO_INITIALIZE(C) C 00151 #else 00152 # define CGAL_SUNPRO_INITIALIZE(C) 00153 #endif 00154 00155 00156 //-------------------------------------------------------------------// 00157 // When the global min and max are no longer defined (as macros) 00158 // because of NOMINMAX flag definition, we define our own global 00159 // min/max functions to make the Microsoft headers compile. (afxtempl.h) 00160 // Users that does not want the global min/max 00161 // should define CGAL_NOMINMAX 00162 //-------------------------------------------------------------------// 00163 #include <algorithm> 00164 #if defined NOMINMAX && !defined CGAL_NOMINMAX 00165 using std::min; 00166 using std::max; 00167 #endif 00168 00169 //-------------------------------------------------------------------// 00170 // Is CORE usable ? 00171 #ifdef CGAL_USE_GMP 00172 # define CGAL_USE_CORE CGAL_USE_GMP 00173 #endif 00174 00175 00176 //-------------------------------------------------------------------// 00177 // Is Geomview usable ? 00178 #if !defined(_MSC_VER) && !defined(__MINGW32__) 00179 # define CGAL_USE_GEOMVIEW 00180 #endif 00181 00182 00183 //-------------------------------------------------------------------// 00184 // Compilers provide different macros to access the current function name 00185 #ifdef _MSC_VER 00186 # define CGAL_PRETTY_FUNCTION __FUNCSIG__ 00187 #elif defined __GNUG__ 00188 # define CGAL_PRETTY_FUNCTION __PRETTY_FUNCTION__ 00189 #else 00190 # define CGAL_PRETTY_FUNCTION __func__ 00191 // with sunpro, this requires -features=extensions 00192 #endif 00193 00194 00195 // Macro to trigger deprecation warnings 00196 #ifdef CGAL_NO_DEPRECATION_WARNINGS 00197 # define CGAL_DEPRECATED 00198 #elif defined (__GNUC__) && (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 1)) 00199 # define CGAL_DEPRECATED __attribute__((__deprecated__)) 00200 #elif defined (_MSC_VER) && (_MSC_VER > 1300) 00201 # define CGAL_DEPRECATED __declspec(deprecated) 00202 #else 00203 # define CGAL_DEPRECATED 00204 #endif 00205 00206 00207 // Macro to specify a noreturn attribute. 00208 #ifdef __GNUG__ 00209 # define CGAL_NORETURN __attribute__ ((__noreturn__)) 00210 #else 00211 # define CGAL_NORETURN 00212 #endif 00213 00214 00215 // If CGAL_HAS_THREADS is not defined, then CGAL code assumes 00216 // it can do any thread-unsafe things (like using static variables). 00217 #if !defined CGAL_HAS_THREADS && !defined CGAL_HAS_NO_THREADS 00218 #if defined BOOST_HAS_THREADS || defined _OPENMP 00219 # define CGAL_HAS_THREADS 00220 #endif 00221 #endif 00222 00223 00224 CGAL_BEGIN_NAMESPACE 00225 00226 // Typedef for the type of NULL. 00227 typedef const void * Nullptr_t; // Anticipate C++0x's std::nullptr_t 00228 00229 CGAL_END_NAMESPACE 00230 00231 #endif // CGAL_CONFIG_H