/Foundation/include/Poco/Config.h

https://github.com/mkrivos/poco · C Header · 226 lines · 28 code · 70 blank · 128 comment · 1 complexity · a600d03b6925bd2b3ddbdfcfd1087bae MD5 · raw file

  1. //
  2. // Config.h
  3. //
  4. // Library: Foundation
  5. // Package: Core
  6. // Module: Foundation
  7. //
  8. // Feature configuration for the POCO libraries.
  9. //
  10. // Copyright (c) 2006-2016, Applied Informatics Software Engineering GmbH.
  11. // and Contributors.
  12. //
  13. // SPDX-License-Identifier: BSL-1.0
  14. //
  15. #ifndef Foundation_Config_INCLUDED
  16. #define Foundation_Config_INCLUDED
  17. #include "Poco/Version.h"
  18. #if POCO_VERSION >= 0x02000000
  19. #define POCO_ENABLE_CPP11
  20. #endif
  21. // Define to enable C++14 support
  22. #ifndef POCO_ENABLE_CPP14
  23. #define POCO_ENABLE_CPP14
  24. #endif
  25. // Compatibility
  26. // Vyriesit ako a ci toto povolit vo WIN, linux to nezere vobec
  27. //#define POCO_WIN32_UTF8
  28. // Define to force disable C++14 support
  29. // #define POCO_DISABLE_CPP14
  30. // Define to disable implicit linking
  31. #define POCO_NO_AUTOMATIC_LIBS
  32. // Define to disable automatic initialization
  33. // Defining this will disable ALL automatic
  34. // initialization framework-wide (e.g. Net
  35. // on Windows, all Data back-ends, etc).
  36. //
  37. // #define POCO_NO_AUTOMATIC_LIB_INIT
  38. // Define to disable FPEnvironment support
  39. // #define POCO_NO_FPENVIRONMENT
  40. // Define if std::wstring is not available
  41. // #define POCO_NO_WSTRING
  42. // Define to disable shared memory
  43. // #define POCO_NO_SHAREDMEMORY
  44. // Define if no <locale> header is available (such as on WinCE)
  45. // #define POCO_NO_LOCALE
  46. // Define to desired default thread stack size
  47. // Zero means OS default
  48. #ifndef POCO_THREAD_STACK_SIZE
  49. #define POCO_THREAD_STACK_SIZE 0
  50. #endif
  51. // Define to override system-provided
  52. // minimum thread priority value on POSIX
  53. // platforms (returned by Poco::Thread::getMinOSPriority()).
  54. // #define POCO_THREAD_PRIORITY_MIN 0
  55. // Define to override system-provided
  56. // maximum thread priority value on POSIX
  57. // platforms (returned by Poco::Thread::getMaxOSPriority()).
  58. // #define POCO_THREAD_PRIORITY_MAX 31
  59. // Define to disable small object optimization. If not
  60. // defined, Any and Dynamic::Var (and similar optimization
  61. // candidates) will be auto-allocated on the stack in
  62. // cases when value holder fits into POCO_SMALL_OBJECT_SIZE
  63. // (see below).
  64. //
  65. // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  66. // !!! NOTE: Any/Dynamic::Var SOO will NOT work reliably !!!
  67. // !!! without C++11 (std::aligned_storage in particular). !!!
  68. // !!! Only comment this out if your compiler has support !!!
  69. // !!! for std::aligned_storage. !!!
  70. // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
  71. //
  72. #ifndef POCO_NO_SOO
  73. #ifndef POCO_ENABLE_SOO
  74. #define POCO_NO_SOO
  75. #endif
  76. #endif
  77. // Small object size in bytes. When assigned to Any or Var,
  78. // objects larger than this value will be alocated on the heap,
  79. // while those smaller will be placement new-ed into an
  80. // internal buffer.
  81. #if !defined(POCO_SMALL_OBJECT_SIZE) && !defined(POCO_NO_SOO)
  82. #define POCO_SMALL_OBJECT_SIZE 32
  83. #endif
  84. // Define to disable compilation of DirectoryWatcher
  85. // on platforms with no inotify.
  86. // #define POCO_NO_INOTIFY
  87. // Following are options to remove certain features
  88. // to reduce library/executable size for smaller
  89. // embedded platforms. By enabling these options,
  90. // the size of a statically executable can be
  91. // reduced by a few 100 Kbytes.
  92. // No automatic registration of FileChannel in
  93. // LoggingFactory - avoids FileChannel and friends
  94. // being linked to executable.
  95. // #define POCO_NO_FILECHANNEL
  96. // No automatic registration of SplitterChannel in
  97. // LoggingFactory - avoids SplitterChannel being
  98. // linked to executable.
  99. // #define POCO_NO_SPLITTERCHANNEL
  100. // No automatic registration of SyslogChannel in
  101. // LoggingFactory - avoids SyslogChannel being
  102. // linked to executable on Unix/Linux systems.
  103. // #define POCO_NO_SYSLOGCHANNEL
  104. // Define to enable MSVC secure warnings
  105. // #define POCO_MSVC_SECURE_WARNINGS
  106. // No support for INI file configurations in
  107. // Poco::Util::Application.
  108. // #define POCO_UTIL_NO_INIFILECONFIGURATION
  109. // No support for JSON configuration in
  110. // Poco::Util::Application. Avoids linking of JSON
  111. // library and saves a few 100 Kbytes.
  112. // #define POCO_UTIL_NO_JSONCONFIGURATION
  113. // No support for XML configuration in
  114. // Poco::Util::Application. Avoids linking of XML
  115. // library and saves a few 100 Kbytes.
  116. // #define POCO_UTIL_NO_XMLCONFIGURATION
  117. // No IPv6 support
  118. // Define to disable IPv6
  119. // #define POCO_NET_NO_IPv6
  120. // Windows CE has no locale support
  121. #if defined(_WIN32_WCE)
  122. #define POCO_NO_LOCALE
  123. #endif
  124. // Enable the poco_debug_* and poco_trace_* macros
  125. // even if the _DEBUG variable is not set.
  126. // This allows the use of these macros in a release version.
  127. // #define POCO_LOG_DEBUG
  128. // Uncomment to disable the use of bundled OpenSSL binaries
  129. // (Windows only)
  130. //#define POCO_EXTERNAL_OPENSSL
  131. // Define to prevent changing the suffix for shared libraries
  132. // to "d.so", "d.dll", etc. for _DEBUG builds in Poco::SharedLibrary.
  133. // #define POCO_NO_SHARED_LIBRARY_DEBUG_SUFFIX
  134. // Disarm POCO_DEPRECATED macro.
  135. // #define POCO_NO_DEPRECATED
  136. // Enable refcounting diagnostic context
  137. // (effective only in conjunction with _DEBUG).
  138. // Enabling this will record every reference
  139. // count change and automatically dump any leaks
  140. // at program termination. It is a heavy
  141. // functionality that records stack backtrace
  142. // (if available, otherwise it is not of much use)
  143. // on every refcount change, so it should be used
  144. // cautiously, with performance deterioration and
  145. // the amount of available memory taken into account.
  146. //#define POCO_REFCOUNT_DC
  147. // Macro defining the default initial size of
  148. // RefCountedObject FastMemoryPool.
  149. // Meaningful only if POCO_REFCOUNT_DC is defined
  150. #ifdef POCO_REFCOUNT_DC
  151. #define POCO_REFCOUNT_POOL_PREALLOC 1000000
  152. #endif // POCO_REFCOUNT_DC
  153. // Macro enabling POCO Exceptions and assertions
  154. // to append stack backtrace (if available)
  155. //#define POCO_EXCEPTION_BACKTRACE
  156. #endif // Foundation_Config_INCLUDED