BuildDefines.h 4.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136
  1. /*
  2. ===========================================================================
  3. Doom 3 GPL Source Code
  4. Copyright (C) 1999-2011 id Software LLC, a ZeniMax Media company.
  5. This file is part of the Doom 3 GPL Source Code (?Doom 3 Source Code?).
  6. Doom 3 Source Code is free software: you can redistribute it and/or modify
  7. it under the terms of the GNU General Public License as published by
  8. the Free Software Foundation, either version 3 of the License, or
  9. (at your option) any later version.
  10. Doom 3 Source Code is distributed in the hope that it will be useful,
  11. but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. GNU General Public License for more details.
  14. You should have received a copy of the GNU General Public License
  15. along with Doom 3 Source Code. If not, see <http://www.gnu.org/licenses/>.
  16. In addition, the Doom 3 Source Code is also subject to certain additional terms. You should have received a copy of these additional terms immediately following the terms and conditions of the GNU General Public License which accompanied the Doom 3 Source Code. If not, please request a copy in writing from id Software at the address below.
  17. If you have questions concerning this license or the applicable additional terms, you may contact in writing id Software LLC, c/o ZeniMax Media Inc., Suite 120, Rockville, Maryland 20850 USA.
  18. ===========================================================================
  19. */
  20. /*
  21. ===============================================================================
  22. Preprocessor settings for compiling different versions.
  23. ===============================================================================
  24. */
  25. // memory debugging
  26. //#define ID_REDIRECT_NEWDELETE
  27. //#define ID_DEBUG_MEMORY
  28. //#define ID_DEBUG_UNINITIALIZED_MEMORY
  29. // if enabled, the console won't toggle upon ~, unless you start the binary with +set com_allowConsole 1
  30. // Ctrl+Alt+~ will always toggle the console no matter what
  31. #ifndef ID_CONSOLE_LOCK
  32. #if defined(_WIN32) || defined(MACOS_X)
  33. #ifdef _DEBUG
  34. #define ID_CONSOLE_LOCK 0
  35. #else
  36. #define ID_CONSOLE_LOCK 1
  37. #endif
  38. #else
  39. #define ID_CONSOLE_LOCK 0
  40. #endif
  41. #endif
  42. // useful for network debugging, turns off 'LAN' checks, all IPs are classified 'internet'
  43. #ifndef ID_NOLANADDRESS
  44. #define ID_NOLANADDRESS 0
  45. #endif
  46. // let .dds be loaded from FS without altering pure state. only for developement.
  47. #ifndef ID_PURE_ALLOWDDS
  48. #define ID_PURE_ALLOWDDS 0
  49. #endif
  50. // build an exe with no CVAR_CHEAT controls
  51. #ifndef ID_ALLOW_CHEATS
  52. #define ID_ALLOW_CHEATS 0
  53. #endif
  54. #ifndef ID_ENABLE_CURL
  55. #define ID_ENABLE_CURL 1
  56. #endif
  57. // fake a pure client. useful to connect an all-debug client to a server
  58. #ifndef ID_FAKE_PURE
  59. #define ID_FAKE_PURE 0
  60. #endif
  61. // verify checksums in clientinfo traffic
  62. // NOTE: this makes the network protocol incompatible
  63. #ifndef ID_CLIENTINFO_TAGS
  64. #define ID_CLIENTINFO_TAGS 0
  65. #endif
  66. // for win32 this is defined in preprocessor settings so that MFC can be
  67. // compiled out.
  68. //#define ID_DEDICATED
  69. // if this is defined, the executable positively won't work with any paks other
  70. // than the demo pak, even if productid is present.
  71. //#define ID_DEMO_BUILD
  72. // don't define ID_ALLOW_TOOLS when we don't want tool code in the executable.
  73. #if defined( _WIN32 ) && !defined( ID_DEDICATED ) && !defined( ID_DEMO_BUILD )
  74. #define ID_ALLOW_TOOLS
  75. #endif
  76. // don't do backtraces in release builds.
  77. // atm, we have no useful way to reconstruct the trace, so let's leave it off
  78. #define ID_BT_STUB
  79. #ifndef ID_BT_STUB
  80. #if defined( __linux__ )
  81. #if defined( _DEBUG )
  82. #define ID_BT_STUB
  83. #endif
  84. #else
  85. #define ID_BT_STUB
  86. #endif
  87. #endif
  88. #ifndef ID_ENFORCE_KEY
  89. # if !defined( ID_DEDICATED ) && !defined( ID_DEMO_BUILD )
  90. # define ID_ENFORCE_KEY 1
  91. # else
  92. # define ID_ENFORCE_KEY 0
  93. # endif
  94. #endif
  95. #ifndef ID_OPENAL
  96. # if ( defined(_WIN32) || defined(MACOS_X) ) && !defined( ID_DEDICATED )
  97. # define ID_OPENAL 1
  98. # else
  99. # define ID_OPENAL 0
  100. # endif
  101. #endif
  102. #ifndef ID_ALLOW_D3XP
  103. # if defined( MACOS_X )
  104. # define ID_ALLOW_D3XP 0
  105. # else
  106. # define ID_ALLOW_D3XP 1
  107. # endif
  108. #endif