From e8c322ee8568b6fbe01625f047f7056aa00cd818 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Thu, 3 Mar 2011 12:00:35 +0000 Subject: Py/RNA API: WITH_PYTHON_SAFETY compile time option which enables extra safety checks. since this is noticeably slower I rather not enable by default yet. --- build_files/scons/tools/btools.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'build_files/scons') diff --git a/build_files/scons/tools/btools.py b/build_files/scons/tools/btools.py index b1b2494d522..d589079a0d4 100644 --- a/build_files/scons/tools/btools.py +++ b/build_files/scons/tools/btools.py @@ -72,7 +72,7 @@ def print_arguments(args, bc): def validate_arguments(args, bc): opts_list = [ - 'WITH_BF_PYTHON', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL', + 'WITH_BF_PYTHON', 'WITH_BF_PYTHON_SAFETY', 'BF_PYTHON', 'BF_PYTHON_VERSION', 'BF_PYTHON_INC', 'BF_PYTHON_BINARY', 'BF_PYTHON_LIB', 'BF_PYTHON_LIBPATH', 'WITH_BF_STATICPYTHON', 'BF_PYTHON_LIB_STATIC', 'BF_PYTHON_DLL', 'WITH_BF_OPENAL', 'BF_OPENAL', 'BF_OPENAL_INC', 'BF_OPENAL_LIB', 'BF_OPENAL_LIBPATH', 'WITH_BF_STATICOPENAL', 'BF_OPENAL_LIB_STATIC', 'WITH_BF_SDL', 'BF_SDL', 'BF_SDL_INC', 'BF_SDL_LIB', 'BF_SDL_LIBPATH', 'BF_LIBSAMPLERATE', 'BF_LIBSAMPLERATE_INC', 'BF_LIBSAMPLERATE_LIB', 'BF_LIBSAMPLERATE_LIBPATH', 'WITH_BF_STATICLIBSAMPLERATE', 'BF_LIBSAMPLERATE_LIB_STATIC', @@ -211,6 +211,7 @@ def read_opts(env, cfg, args): localopts.AddVariables( ('LCGDIR', 'location of cvs lib dir'), (BoolVariable('WITH_BF_PYTHON', 'Compile with python', True)), + (BoolVariable('WITH_BF_PYTHON_SAFETY', 'Internal API error checking to track invalid data to prevent crash on access (at the expense of some effeciency)', False)), ('BF_PYTHON', 'base path for python', ''), ('BF_PYTHON_VERSION', 'Python version to use', ''), ('BF_PYTHON_INC', 'include path for Python headers', ''), -- cgit v1.2.3