Browse Source

Default to ENABLE_SAFE_LUA=0 for improved performance.

Lasse Öörni 12 years ago
parent
commit
165b7c8eae
3 changed files with 3 additions and 6 deletions
  1. 1 1
      Docs/GettingStarted.dox
  2. 1 1
      Readme.txt
  3. 1 4
      Source/Extras/LuaScript/CMakeLists.txt

+ 1 - 1
Docs/GettingStarted.dox

@@ -126,11 +126,11 @@ A number of build options can be defined explicitly when invoking the above cmak
 |-DENABLE_64BIT=1                             |to enable 64bit build|
 |-DENABLE_LUA=1                               |to enable additional Lua scripting support|
 |-DENABLE_LUA_JIT=1                           |to enable Lua Just-in-time compilation|
+|-DENABLE_SAFE_LUA=1                          |to enable Lua C++ wrapper safety checks|
 |-DENABLE_SAMPLES=1                           |to build the C++ sample applications|
 |-DENABLE_TOOLS=1                             |to build the tools (only useful for Raspberry Pi build because this option is already enabled by default for other Desktop platforms)|
 |-DENABLE_SSE=0                               |to disable SSE instruction set|
 |-DENABLE_MINIDUMPS=0                         |to disable minidumps on crash (VS only)|
-|-DENABLE_SAFE_LUA=0                          |to disable Lua C++ wrapper safety for performance|
 |-DUSE_OPENGL=1                               |to use OpenGL instead of Direct3D (only useful for VS on Windows platform because this option is enabled by default for other platforms)|
 |-DUSE_MKLINK=1                               |to use mklink command to create symbolic links (Windows Vista and above only)|
 |-DUSE_STATIC_RUNTIME=1                       |to use static C/C++ runtime libraries and eliminate the need for runtime DLLs installation (VS only)|

+ 1 - 1
Readme.txt

@@ -358,13 +358,13 @@ cmake_xxxx batch files or shell scripts.
 |-DENABLE_64BIT=1      |to enable 64bit build                                  |
 |-DENABLE_LUA=1        |to enable additional Lua scripting support             |
 |-DENABLE_LUA_JIT=1    |to enable Lua Just-in-time compilation                 |
+|-DENABLE_SAFE_LUA=1   |to enable Lua C++ wrapper safety checks                |
 |-DENABLE_SAMPLES=1    |to build the C++ sample applications                   |
 |-DENABLE_TOOLS=1      |to build the tools (only useful for Raspberry Pi build |
 |                      | because this option is already enabled by default for |
 |                      | other Desktop platforms)                              |
 |-DENABLE_SSE=0        |to disable SSE instruction set                         |
 |-DENABLE_MINIDUMPS=0  |to disable minidumps on crash (VS only)                |
-|-DENABLE_SAFE_LUA=0   |to disable Lua C++ wrapper safety for performance      |
 |-DUSE_OPENGL=1        |to use OpenGL instead of Direct3D (only useful for VS  |
 |                      | on Windows platform because this option is enabled by |
 |                      | default for other platforms)                          | 

+ 1 - 4
Source/Extras/LuaScript/CMakeLists.txt

@@ -23,10 +23,7 @@
 # Define target name
 set (TARGET_NAME LuaScript)
 
-# Enable Lua / C++ wrapper safety checks by default. These can be disabled for performance
-if (NOT DEFINED ENABLE_SAFE_LUA)
-    set (ENABLE_SAFE_LUA 1)
-endif ()
+# Optionally enable Lua / C++ wrapper safety checks
 if (NOT ENABLE_SAFE_LUA)
     add_definitions (-DTOLUA_RELEASE)
 endif ()