epoc32/include/tools/stlport/stl/config/user_config.h
author William Roberts <williamr@symbian.org>
Tue, 16 Mar 2010 16:12:26 +0000
branchSymbian2
changeset 2 2fe1408b6811
permissions -rw-r--r--
Final list of Symbian^2 public API header files
     1 /*
     2  * Copyright (c) 1999
     3  * Boris Fomitchev
     4  *
     5  * This material is provided "as is", with absolutely no warranty expressed
     6  * or implied. Any use is at your own risk.
     7  *
     8  * Permission to use or copy this software for any purpose is hereby granted
     9  * without fee, provided the above notices are retained on all copies.
    10  * Permission to modify the code and to distribute modified code is granted,
    11  * provided the above notices are retained, and a notice that the code was
    12  * modified is included with the above copyright notice.
    13  */
    14 
    15 /*
    16  * Purpose of this file :
    17  *
    18  * To hold user-definable portion of STLport settings which may be overridden
    19  * on per-project basis.
    20  * Please note that if you use STLport iostreams (compiled library) then you have
    21  * to use consistent settings when you compile STLport library and your project.
    22  * Those settings are defined in host.h and have to be the same for a given
    23  * STLport installation.
    24  */
    25 
    26 
    27 /*==========================================================
    28  * User-settable macros that control compilation:
    29  *              Features selection
    30  *==========================================================*/
    31 
    32 /*
    33  * Use this switch for embedded systems where no iostreams are available
    34  * at all. STLport own iostreams will also get disabled automatically then.
    35  * You can either use STLport iostreams, or no iostreams.
    36  * If you want iostreams, you have to compile library in ../build/lib
    37  * and supply resulting library at link time.
    38  */
    39 /*
    40 #define _STLP_NO_IOSTREAMS 1
    41 */
    42 
    43 /*
    44  * Set _STLP_DEBUG to turn the "Debug Mode" on.
    45  * That gets you checked iterators/ranges in the manner
    46  * of "Safe STL". Very useful for debugging. Thread-safe.
    47  * Please do not forget to link proper STLport library flavor
    48  * (e.g libstlportstlg.so or libstlportstlg.a) when you set this flag
    49  * in STLport iostreams mode, namespace customization guaranty that you
    50  * link to the right library.
    51  */
    52 /*
    53 #define _STLP_DEBUG 1
    54 */
    55 /*
    56  * You can also choose the debug level:
    57  * STLport debug level: Default value
    58  *                      Check only what the STLport implementation consider as invalid.
    59  *                      It also change the iterator invalidation schema.
    60  * Standard debug level: Check for all operations the standard consider as "undefined behavior"
    61  *                       even if STlport implement it correctly. It also invalidates iterators
    62  *                       more often.
    63  */
    64 /*
    65 #define   _STLP_DEBUG_LEVEL _STLP_STLPORT_DBG_LEVEL
    66 #define   _STLP_DEBUG_LEVEL _STLP_STANDARD_DBG_LEVEL
    67 */
    68 /* When an inconsistency is detected by the 'safe STL' the program will abort.
    69  * If you prefer an exception define the following macro. The thrown exception
    70  * will be the Standard runtime_error exception.
    71  */
    72 /*
    73 #define _STLP_DEBUG_MODE_THROWS
    74  */
    75 
    76 /*
    77  * _STLP_NO_CUSTOM_IO : define this if you do not instantiate basic_xxx iostream
    78  * classes with custom types (which is most likely the case). Custom means types
    79  * other than char, wchar_t, char_traits<> and allocator<> like
    80  * basic_ostream<my_char_type, my_traits<my_char_type> > or
    81  * basic_string<char, char_traits<char>, my_allocator >
    82  * When this option is on, most non-inline template functions definitions for iostreams
    83  * are not seen by the client which saves a lot of compile time for most compilers,
    84  * also object and executable size for some.
    85  * Default is off, just not to break compilation for those who do use those types.
    86  * That also guarantees that you still use optimized standard i/o when you compile
    87  * your program without optimization. Option does not affect STLport library build; you
    88  * may use the same binary library with and without this option, on per-project basis.
    89  */
    90 /*
    91 #define _STLP_NO_CUSTOM_IO
    92 */
    93 
    94 /*
    95  * _STLP_NO_RELOPS_NAMESPACE: if defined, don't put the relational
    96  * operator templates (>, <=. >=, !=) in namespace std::rel_ops, even
    97  * if the compiler supports namespaces.
    98  * Note : if the compiler do not support namespaces, those operators are not be provided by default,
    99  * to simulate hiding them into rel_ops. This was proved to resolve many compiler bugs with ambiguity.
   100  */
   101 /*
   102 #define _STLP_NO_RELOPS_NAMESPACE 1
   103 */
   104 
   105 /*
   106  * If _STLP_USE_OWN_NAMESPACE is in effect, STLport by default will try
   107  * to rename std:: for the user to stlport::. If you do not want this feature,
   108  * please define the following switch and then use stlport::
   109  */
   110 /*
   111 #define _STLP_DONT_REDEFINE_STD 1
   112 */
   113 
   114 /*
   115  * _STLP_WHOLE_NATIVE_STD : only meaningful in _STLP_USE_OWN_NAMESPACE mode.
   116  * Normally, STLport only imports necessary components from native std:: namespace -
   117  * those not yet provided by STLport (<iostream>, <complex>, etc.)
   118  * and their dependencies (<string>, <stdexcept>).
   119  * You might want everything from std:: being available in std:: namespace when you
   120  * include corresponding STLport header (like STLport <map> provides std::map as well, etc.),
   121  * if you are going to use both stlport:: and std:: components in your code.
   122  * Otherwise this option is not recommended as it increases the size of your object files
   123  * and slows down compilation.
   124  */
   125 /*
   126 #define _STLP_WHOLE_NATIVE_STD
   127 */
   128 
   129 /*
   130  * Use this option to catch uninitialized members in your classes.
   131  * When it is set, construct() and destroy() fill the class storage
   132  * with _STLP_SHRED_BYTE (see below).
   133  * Note : _STLP_DEBUG and _STLP_DEBUG_ALLOC don't set this option automatically.
   134  */
   135 /*
   136 #define _STLP_DEBUG_UNINITIALIZED 1
   137 #define _STLP_DEBUG_ALLOC 1
   138 */
   139 
   140 /*
   141  * Uncomment and provide a definition for the byte with which raw memory
   142  * will be filled if _STLP_DEBUG_ALLOC or _STLP_DEBUG_UNINITIALIZED is defined.
   143  * Choose a value which is likely to cause a noticeable problem if dereferenced
   144  * or otherwise abused. A good value may already be defined for your platform; see
   145  * stl/_config.h
   146  */
   147 /*
   148 #define _STLP_SHRED_BYTE 0xA3
   149 */
   150 
   151 /*
   152  *  This option is for gcc users only and only affects systems where native linker
   153  *  does not let gcc to implement automatic instantiation of static template data members/
   154  *  It is being put in this file as there is no way to check if we are using GNU ld automatically,
   155  *  so it becomes user's responsibility.
   156  */
   157 /*
   158 #define _STLP_GCC_USES_GNU_LD
   159 */
   160 
   161 /*==========================================================
   162  * Compatibility section
   163  *==========================================================*/
   164 
   165 /*
   166  *  Define this macro to disable anachronistic constructs (like the ones used in HP STL and
   167  *  not included in final standard, etc.
   168  */
   169 /*
   170 #define _STLP_NO_ANACHRONISMS 1
   171 */
   172 
   173 /*
   174  *  Define this macro to disable STLport extensions (for example, to make sure your code will
   175  *  compile with some other implementation )
   176  */
   177 /*
   178 #define _STLP_NO_EXTENSIONS 1
   179 */
   180 
   181 /*
   182  * You should define this macro if compiling with MFC - STLport <stl/_config.h>
   183  * then include <afx.h> instead of <windows.h> to get synchronisation primitives
   184  */
   185 /*
   186 #define _STLP_USE_MFC 1
   187 */
   188 
   189 /*
   190  * boris : this setting is here as we cannot detect precense of new Platform SDK automatically
   191  * If you are using new PSDK with VC++ 6.0 or lower,
   192  * please define this to get correct prototypes for InterlockedXXX functions
   193  */
   194 /*
   195 #define _STLP_NEW_PLATFORM_SDK 1
   196 */
   197 
   198 /*
   199  * For the same reason as the one above we are not able to detect easily use
   200  * of the compiler coming with the Platform SDK instead of the one coming with
   201  * a Microsoft Visual Studio release. This change native C/C++ library location
   202  * and implementation, please define this to get correct STLport configuration.
   203  */
   204 /*
   205 #define _STLP_USING_PLATFORM_SDK_COMPILER 1
   206 */
   207 
   208 /*
   209  * Some compilers support the automatic linking feature.
   210  * Uncomment the following if you prefer to specify the STLport library
   211  * to link with yourself.
   212  * For the moment, this feature is only supported and implemented within STLport
   213  * by the Microsoft compilers.
   214  */
   215 /*
   216 #define _STLP_DONT_USE_AUTO_LINK 1
   217 */
   218 
   219 /*
   220  * If you customize the STLport generated library names don't forget to give
   221  * the motif you used during configuration here if you still want the auto link
   222  * to work. (Do not remove double quotes in the macro value)
   223  */
   224 /*
   225 #define _STLP_LIB_NAME_MOTIF "???"
   226  */
   227 
   228 /*
   229  * When using automatic linking (see above), output a message that tells the
   230  * user which lib is getting linked via 'pragma message(..)'.
   231  * This setting has no effect if automatic linking is not active.
   232  */
   233 /*
   234 #define _STLP_VERBOSE_AUTO_LINK 1
   235 */
   236 
   237 /*
   238  * Use minimum set of default arguments on template classes that have more
   239  * than one - for example map<>, set<>.
   240  * This has effect only if _STLP_LIMITED_DEFAULT_TEMPLATES is on.
   241  * If _STLP_MINIMUM_DEFAULT_TEMPLATE_PARAMS is set, you'll be able to compile
   242  * set<T> with those compilers, but you'll have to use __set__<T, less<T>>
   243  *
   244  * Affects : map<>, multimap<>, set<>, multiset<>, hash_*<>,
   245  * queue<>, priority_queue<>, stack<>, istream_iterator<>
   246  */
   247 /*
   248 #define _STLP_MINIMUM_DEFAULT_TEMPLATE_PARAMS 1
   249 */
   250 
   251 /*
   252  * The agregation of strings using the + operator is an expensive operation
   253  * as it requires construction of temporary objects that need memory allocation
   254  * and deallocation. The problem can be even more important if you are adding
   255  * several strings together in a single expression. To avoid this problem STLport
   256  * implement expression template. With this technique addition of 2 strings is not
   257  * a string anymore but a temporary object having a reference to each of the
   258  * original strings involved in the expression. This object carry information
   259  * directly to the destination string to set its size correctly and only make
   260  * a single call to the allocator. This technique also works for the addition of
   261  * N elements where elements are basic_string, C string or a single character.
   262  * The drawback can be longer compilation time and bigger executable size.
   263  * STLport rebuild: Yes
   264  */
   265 /*
   266 #define _STLP_USE_TEMPLATE_EXPRESSION 1
   267 */
   268 
   269 /*
   270  * By default the STLport basic_string implementation use a little static buffer
   271  * (of 16 chars when writing this doc) to avoid systematically memory allocation
   272  * in case of little basic_string. The drawback of such a method is bigger
   273  * basic_string size and some performance penalty for method like swap. If you
   274  * prefer systematical dynamic allocation turn on this macro.
   275  * STLport rebuild: Yes
   276  */
   277 /*
   278 #define _STLP_DONT_USE_SHORT_STRING_OPTIM 1
   279 */
   280 
   281 /*
   282  * To reduce the famous code bloat trouble due to the use of templates STLport grant
   283  * a specialization of some containers for pointer types. So all instanciations
   284  * of those containers with a pointer type will use the same implementation based on
   285  * a container of void*. This feature has show very good result on object files size
   286  * but after link phase and optimization you will only experiment benefit if you use
   287  * many container with pointer types.
   288  */
   289 /*
   290 #define _STLP_USE_PTR_SPECIALIZATIONS 1
   291 */
   292 
   293 /*
   294  * To achieve many different optimizations within the template implementations STLport
   295  * uses some type traits technique. With this macro you can ask STLport to use the famous
   296  * boost type traits rather than the internal one. The advantages are more compiler
   297  * integration and a better support. If you only define this macro once the STLport has been
   298  * built you just have to add the boost install path within your include path. If you want
   299  * to use this feature at STLport built time you will have to define the
   300  * STLP_BUILD_BOOST_PATH enrironment variable with the value of the boost library path.
   301  */
   302 /*
   303 #define _STLP_USE_BOOST_SUPPORT 1
   304 */
   305 
   306 /*==========================================================*/
   307 
   308 /*
   309   Local Variables:
   310   mode: C++
   311   End:
   312 */