borland.hpp

Go to the documentation of this file.
00001 //  (C) Copyright John Maddock 2001 - 2003.
00002 //  (C) Copyright David Abrahams 2002 - 2003.
00003 //  (C) Copyright Aleksey Gurtovoy 2002.
00004 //  Use, modification and distribution are subject to the
00005 //  Boost Software License, Version 1.0. (See accompanying file
00006 //  LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
00007 
00008 //  See http://www.boost.org for most recent version.
00009 
00010 //  Borland C++ compiler setup:
00011 
00012 // Version 5.0 and below:
00013 #   if __BORLANDC__ <= 0x0550
00014 // Borland C++Builder 4 and 5:
00015 #     define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
00016 #     if __BORLANDC__ == 0x0550
00017 // Borland C++Builder 5, command-line compiler 5.5:
00018 #       define BOOST_NO_OPERATORS_IN_NAMESPACE
00019 #     endif
00020 #   endif
00021 
00022 // Version 5.51 and below:
00023 #if (__BORLANDC__ <= 0x551)
00024 #  define BOOST_NO_CV_SPECIALIZATIONS
00025 #  define BOOST_NO_CV_VOID_SPECIALIZATIONS
00026 #  define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
00027 #  define BOOST_NO_DEDUCED_TYPENAME
00028 // workaround for missing WCHAR_MAX/WCHAR_MIN:
00029 #include <climits>
00030 #include <cwchar>
00031 #ifndef WCHAR_MAX
00032 #  define WCHAR_MAX 0xffff
00033 #endif
00034 #ifndef WCHAR_MIN
00035 #  define WCHAR_MIN 0
00036 #endif
00037 #endif
00038 
00039 // Version 7.0 (Kylix) and below:
00040 #if (__BORLANDC__ <= 0x570)
00041 #  define BOOST_NO_SFINAE
00042 #  define BOOST_NO_INTEGRAL_INT64_T
00043 #  define BOOST_NO_DEPENDENT_NESTED_DERIVATIONS
00044 #  define BOOST_NO_PRIVATE_IN_AGGREGATE
00045 #  define BOOST_NO_USING_TEMPLATE
00046 #  define BOOST_BCB_PARTIAL_SPECIALIZATION_BUG
00047 #  define BOOST_NO_TEMPLATE_TEMPLATES
00048 #  define BOOST_NO_USING_DECLARATION_OVERLOADS_FROM_TYPENAME_BASE
00049 #  define BOOST_NO_MEMBER_TEMPLATE_FRIENDS
00050    // we shouldn't really need this - but too many things choke
00051    // without it, this needs more investigation:
00052 #  define BOOST_NO_LIMITS_COMPILE_TIME_CONSTANTS
00053 #  define BOOST_FUNCTION_SCOPE_USING_DECLARATION_BREAKS_ADL
00054 #  define BOOST_NO_IS_ABSTRACT
00055 #  ifdef NDEBUG
00056       // fix broken <cstring> so that Boost.test works:
00057 #     include <cstring>
00058 #     undef strcmp
00059 #  endif
00060 
00061 //
00062 // new bug in 5.61:
00063 #if (__BORLANDC__ >= 0x561) && (__BORLANDC__ <= 0x570)
00064    // this seems to be needed by the command line compiler, but not the IDE:
00065 #  define BOOST_NO_MEMBER_FUNCTION_SPECIALIZATIONS
00066 #endif
00067 
00068 #  ifdef _WIN32
00069 #     define BOOST_NO_SWPRINTF
00070 #  elif defined(linux) || defined(__linux__) || defined(__linux)
00071       // we should really be able to do without this
00072       // but the wcs* functions aren't imported into std::
00073 #     define BOOST_NO_STDC_NAMESPACE
00074       // _CPPUNWIND doesn't get automatically set for some reason:
00075 #     pragma defineonoption BOOST_CPPUNWIND -x
00076 #  endif
00077 #endif
00078 
00079 //
00080 // Post 0x561 we have long long and stdint.h:
00081 #if __BORLANDC__ >= 0x561
00082 #  ifndef __NO_LONG_LONG
00083 #     define BOOST_HAS_LONG_LONG
00084 #  endif
00085    // On non-Win32 platforms let the platform config figure this out:
00086 #  ifdef _WIN32
00087 #      define BOOST_HAS_STDINT_H
00088 #  endif
00089 #endif
00090 
00091 // Borland C++Builder 6 defaults to using STLPort.  If _USE_OLD_RW_STL is
00092 // defined, then we have 0x560 or greater with the Rogue Wave implementation
00093 // which presumably has the std::DBL_MAX bug.
00094 #if ((__BORLANDC__ >= 0x550) && (__BORLANDC__ < 0x560)) || defined(_USE_OLD_RW_STL)
00095 // <climits> is partly broken, some macros define symbols that are really in
00096 // namespace std, so you end up having to use illegal constructs like
00097 // std::DBL_MAX, as a fix we'll just include float.h and have done with:
00098 #include <float.h>
00099 #endif
00100 //
00101 // __int64:
00102 //
00103 #if (__BORLANDC__ >= 0x530) && !defined(__STRICT_ANSI__)
00104 #  define BOOST_HAS_MS_INT64
00105 #endif
00106 //
00107 // check for exception handling support:
00108 //
00109 #if !defined(_CPPUNWIND) && !defined(BOOST_CPPUNWIND) && !defined(__EXCEPTIONS)
00110 #  define BOOST_NO_EXCEPTIONS
00111 #endif
00112 //
00113 // all versions have a <dirent.h>:
00114 //
00115 #ifndef __STRICT_ANSI__
00116 #  define BOOST_HAS_DIRENT_H
00117 #endif
00118 //
00119 // all versions support __declspec:
00120 //
00121 #ifndef __STRICT_ANSI__
00122 #  define BOOST_HAS_DECLSPEC
00123 #endif
00124 //
00125 // ABI fixing headers:
00126 //
00127 #if __BORLANDC__ < 0x600 // not implemented for version 6 compiler yet
00128 #ifndef BOOST_ABI_PREFIX
00129 #  define BOOST_ABI_PREFIX "sysc/packages/boost/config/abi/borland_prefix.hpp"
00130 #endif
00131 #ifndef BOOST_ABI_SUFFIX
00132 #  define BOOST_ABI_SUFFIX "sysc/packages/boost/config/abi/borland_suffix.hpp"
00133 #endif
00134 #endif
00135 //
00136 // Disable Win32 support in ANSI mode:
00137 //
00138 #if __BORLANDC__ < 0x600
00139 #  pragma defineonoption BOOST_DISABLE_WIN32 -A
00140 #elif defined(__STRICT_ANSI__)
00141 #  define BOOST_DISABLE_WIN32
00142 #endif
00143 //
00144 // MSVC compatibility mode does some nasty things:
00145 //
00146 #if defined(_MSC_VER) && (_MSC_VER <= 1200)
00147 #  define BOOST_NO_ARGUMENT_DEPENDENT_LOOKUP
00148 #  define BOOST_NO_VOID_RETURNS
00149 #endif
00150 
00151 #define BOOST_COMPILER "Borland C++ version " BOOST_STRINGIZE(__BORLANDC__)
00152 
00153 //
00154 // versions check:
00155 // we don't support Borland prior to version 5.4:
00156 #if __BORLANDC__ < 0x540
00157 #  error "Compiler not supported or configured - please reconfigure"
00158 #endif
00159 //
00160 // last known and checked version is 1536 (Builder X preview):
00161 #if (__BORLANDC__ > 1536)
00162 #  if defined(BOOST_ASSERT_CONFIG)
00163 #     error "Unknown compiler version - please run the configure tests and report the results"
00164 #  else
00165 #     pragma message( "Unknown compiler version - please run the configure tests and report the results")
00166 #  endif
00167 #endif
00168 
00169 
00170 
00171 
00172 
00173 
00174 
00175 

Generated on Wed Jan 21 15:32:09 2009 for SystemC by  doxygen 1.5.5