Bug 1496198 - Simplify --enable-rust-debug handling r=froydnj
authorMike Hommey <mh+mozilla@glandium.org>
Thu, 04 Oct 2018 13:39:24 +0000
changeset 439746 5f50bfa10bd626bc595ca53f78d3d4ba7f1e03ff
parent 439745 4b0eafbca6e86b5e1df7bab083b3d785dfb0f4cb
child 439747 01a517eeb9e6aaa9f5973599976a0dfcebbbbe8f
push id108654
push userncsoregi@mozilla.com
push dateFri, 05 Oct 2018 04:49:52 +0000
treeherdermozilla-inbound@2a6ec2aae9fd [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1496198 - Simplify --enable-rust-debug handling r=froydnj making its value propagate properly to js/src subconfigure. Differential Revision: https://phabricator.services.mozilla.com/D7688
--- a/moz.configure
+++ b/moz.configure
@@ -109,24 +109,22 @@ def moz_debug(debug):
 set_config('MOZ_DEBUG', moz_debug)
 set_define('MOZ_DEBUG', moz_debug)
 # Override any value MOZ_DEBUG may have from the environment when passing it
 # down to old-configure.
                              depends('--enable-debug')(lambda x: bool(x)))
+          default=depends(when='--enable-debug')(lambda: True),
           help='Build Rust code with debug assertions turned on.')
-@depends('--enable-rust-debug', '--enable-debug')
-def debug_rust(value, debug):
-    if value.origin == 'default':
-        return bool(debug) or None
-    elif bool(value):
-        return True
+def debug_rust():
+    return True
 set_config('MOZ_DEBUG_RUST', debug_rust)
 set_define('MOZ_DEBUG_RUST', debug_rust)
 # Make this assignment here rather than in pkg.configure to avoid
 # requiring this file in unit tests.
 add_old_configure_assignment('PKG_CONFIG', pkg_config)