diff options
author | Waley Chen <waleycz@gmail.com> | 2016-04-11 17:23:59 -0400 |
---|---|---|
committer | Waley Chen <waleycz@gmail.com> | 2016-04-14 14:58:29 -0400 |
commit | 0f1f80e2f7cf0ca1fbc9354b5fa2fad705207677 (patch) | |
tree | ee9535bda9ca68676c563e05e8aae2a4ba77ae79 | |
parent | 6056752d4e5a028418412f50d1f2f3b965dc0e6f (diff) | |
download | mongo-0f1f80e2f7cf0ca1fbc9354b5fa2fad705207677.tar.gz |
SERVER-23571 Make debug builds of SpiderMonkey distinct from --dbg in scons
(cherry picked from commit 95d6f8c8a4e8a3645d3e9e42f070a28eaaf5c97e)
-rw-r--r-- | SConstruct | 9 | ||||
-rw-r--r-- | src/mongo/scripting/SConscript | 4 | ||||
-rw-r--r-- | src/third_party/mozjs-38/SConscript | 4 |
3 files changed, 13 insertions, 4 deletions
diff --git a/SConstruct b/SConstruct index f68d4f65a01..6a53a8f4079 100644 --- a/SConstruct +++ b/SConstruct @@ -244,6 +244,15 @@ add_option('dbg', type='choice', ) +add_option('spider-monkey-dbg', + choices=['on', 'off'], + const='on', + default='off', + help='Enable SpiderMonkey debug mode', + nargs='?', + type='choice', +) + add_option('opt', choices=['on', 'off'], const='on', diff --git a/src/mongo/scripting/SConscript b/src/mongo/scripting/SConscript index c27e780985a..3f1e034fa40 100644 --- a/src/mongo/scripting/SConscript +++ b/src/mongo/scripting/SConscript @@ -1,8 +1,8 @@ # -*- mode: python -*- Import([ - 'debugBuild', 'env', + 'get_option', 'serverJs', 'usemozjs', ]) @@ -86,7 +86,7 @@ if usemozjs: 'STATIC_JS_API=1', ]) - if debugBuild: + if get_option('spider-monkey-dbg') == "on": scriptingEnv.Prepend(CPPDEFINES=[ 'DEBUG', 'JS_DEBUG', diff --git a/src/third_party/mozjs-38/SConscript b/src/third_party/mozjs-38/SConscript index bcb8e684f8b..6d073ea5b2c 100644 --- a/src/third_party/mozjs-38/SConscript +++ b/src/third_party/mozjs-38/SConscript @@ -1,8 +1,8 @@ # -*- mode: python -*- Import([ - "debugBuild", "env", + "get_option", ]) env = env.Clone() @@ -28,7 +28,7 @@ env.Prepend(CPPDEFINES=[ 'U_NO_DEFAULT_INCLUDE_UTF_HEADERS=1', ]) -if debugBuild: +if get_option('spider-monkey-dbg') == "on": env.Prepend(CPPDEFINES=[ 'DEBUG', 'JS_DEBUG', |