From 0ea268dc18e2205bf86574ed0c2a3eb0d8b51354 Mon Sep 17 00:00:00 2001 From: Mike Hommey Date: Tue, 22 Mar 2016 08:26:57 +0900 Subject: [PATCH] Backout changesets f5090987b7c6, 48a94777837d and a63437a74f7a (bug 1257468) for SM bustage on a CLOSED TREE --- build/autoconf/ffi.m4 | 2 +- build/autoconf/icu.m4 | 2 +- build/autoconf/jemalloc.m4 | 2 +- build/autoconf/nspr-build.m4 | 12 ++++++------ build/moz.configure/init.configure | 3 --- configure.py | 4 ++-- js/moz.configure | 26 ++++++++------------------ js/src/old-configure.in | 8 +++++++- old-configure.in | 5 ++++- 9 files changed, 30 insertions(+), 34 deletions(-) diff --git a/build/autoconf/ffi.m4 b/build/autoconf/ffi.m4 index ebacd8b16abd..369460cfb61c 100644 --- a/build/autoconf/ffi.m4 +++ b/build/autoconf/ffi.m4 @@ -23,7 +23,7 @@ AC_SUBST(MOZ_SYSTEM_FFI) ]) AC_DEFUN([MOZ_SUBCONFIGURE_FFI], [ -if test "$MOZ_BUILD_APP" != js -o -n "$JS_STANDALONE"; then +if test -z "$BUILDING_JS" -o -n "$JS_STANDALONE"; then if test "$BUILD_CTYPES" -a -z "$MOZ_SYSTEM_FFI"; then # Run the libffi 'configure' script. diff --git a/build/autoconf/icu.m4 b/build/autoconf/icu.m4 index 3d814f50d8ed..037af7151f62 100644 --- a/build/autoconf/icu.m4 +++ b/build/autoconf/icu.m4 @@ -128,7 +128,7 @@ fi AC_DEFUN([MOZ_SUBCONFIGURE_ICU], [ -if test "$MOZ_BUILD_APP" != js -o -n "$JS_STANDALONE"; then +if test -z "$BUILDING_JS" -o -n "$JS_STANDALONE"; then if test -n "$USE_ICU" -a -z "$MOZ_SYSTEM_ICU"; then # Set ICU compile options diff --git a/build/autoconf/jemalloc.m4 b/build/autoconf/jemalloc.m4 index da76d92cefe3..05f5979d8278 100644 --- a/build/autoconf/jemalloc.m4 +++ b/build/autoconf/jemalloc.m4 @@ -4,7 +4,7 @@ dnl file, You can obtain one at http://mozilla.org/MPL/2.0/. AC_DEFUN([MOZ_SUBCONFIGURE_JEMALLOC], [ -if test "$MOZ_BUILD_APP" != js -o -n "$JS_STANDALONE"; then +if test -z "$BUILDING_JS" -o -n "$JS_STANDALONE"; then # Run jemalloc configure script diff --git a/build/autoconf/nspr-build.m4 b/build/autoconf/nspr-build.m4 index fe6dab7210e7..a641d0596b99 100644 --- a/build/autoconf/nspr-build.m4 +++ b/build/autoconf/nspr-build.m4 @@ -8,11 +8,11 @@ ifelse([$1],,define(CONFIGURING_JS,yes)) dnl Possible ways this can be called: dnl from toplevel configure: -dnl JS_STANDALONE= MOZ_BUILD_APP!=js +dnl JS_STANDALONE= BUILDING_JS= dnl from js/src/configure invoked by toplevel configure: -dnl JS_STANDALONE= MOZ_BUILD_APP=js +dnl JS_STANDALONE= BUILDING_JS=1 dnl from standalone js/src/configure: -dnl JS_STANDALONE=1 MOZ_BUILD_APP=js +dnl JS_STANDALONE=1 BUILDING_JS=1 dnl ======================================================== dnl = Find the right NSPR to use. @@ -38,7 +38,7 @@ ifdef([CONFIGURING_JS],[ MOZ_BUILD_NSPR=) ]) -if test "$MOZ_BUILD_APP" != js || test -n "$JS_STANDALONE"; then +if test -z "$BUILDING_JS" || test -n "$JS_STANDALONE"; then _IS_OUTER_CONFIGURE=1 fi @@ -99,7 +99,7 @@ else fi if test -z "$nspr_opts"; then - if test "$MOZ_BUILD_APP" != js; then + if test -z "$BUILDING_JS"; then dnl Toplevel configure defaults to using nsprpub from the source tree MOZ_BUILD_NSPR=1 which_nspr="source-tree" @@ -124,7 +124,7 @@ fi AC_SUBST(MOZ_BUILD_NSPR) -if test "$MOZ_BUILD_APP" = js; then +if test -n "$BUILDING_JS"; then if test "$JS_POSIX_NSPR" = 1; then AC_DEFINE(JS_POSIX_NSPR) fi diff --git a/build/moz.configure/init.configure b/build/moz.configure/init.configure index e28bbe68ad07..b64ae3d72d2a 100644 --- a/build/moz.configure/init.configure +++ b/build/moz.configure/init.configure @@ -255,7 +255,6 @@ def wanted_mozconfig_variables(help): 'DSYMUTIL', 'EXTERNAL_SOURCE_DIR', 'GENISOIMAGE', - 'JS_STANDALONE', 'L10NBASEDIR', 'MOZILLABUILD', 'MOZ_ARTIFACT_BUILDS', @@ -581,8 +580,6 @@ def include_project_configure(project, external_source_dir, build_env, help): def build_project(include_project_configure, build_env, help): ret = os.path.dirname(os.path.relpath(include_project_configure, build_env['TOPSRCDIR'])) - set_config('MOZ_BUILD_APP', ret) - set_define('MOZ_BUILD_APP', ret) add_old_configure_assignment('MOZ_BUILD_APP', ret) return ret diff --git a/configure.py b/configure.py index 2ad8e83a35c4..f3192caef2e5 100644 --- a/configure.py +++ b/configure.py @@ -58,7 +58,7 @@ def config_status(config): fh.write("__all__ = ['topobjdir', 'topsrcdir', 'defines', " "'non_global_defines', 'substs']") - if config.get('MOZ_BUILD_APP') != 'js' or config.get('JS_STANDALONE'): + if not config.get('BUILDING_JS') or config.get('JS_STANDALONE'): fh.write(''' if __name__ == '__main__': args = dict([(name, globals()[name]) for name in __all__]) @@ -69,7 +69,7 @@ if __name__ == '__main__': # Other things than us are going to run this file, so we need to give it # executable permissions. os.chmod('config.status', 0755) - if config.get('MOZ_BUILD_APP') != 'js' or config.get('JS_STANDALONE'): + if not config.get('BUILDING_JS') or config.get('JS_STANDALONE'): if not config.get('JS_STANDALONE'): os.environ['WRITE_MOZINFO'] = '1' # Until we have access to the virtualenv from this script, execute diff --git a/js/moz.configure b/js/moz.configure index 4e24f4c60fec..21ffb9468d76 100644 --- a/js/moz.configure +++ b/js/moz.configure @@ -8,24 +8,10 @@ # ========================================================= @depends(build_project, '--help') -def building_js(build_project, help): +def js_shell_default(build_project, help): return build_project == 'js' -# Exception to the rule above: JS_STANDALONE is a special option that doesn't -# want the js_option treatment. When we're done merging js/src/configure and -# top-level configure, it can go away, although the JS_STANDALONE config -# will still need to be set depending on building_js above. -option(env='JS_STANDALONE', default=building_js, - help='Reserved for internal use') - -@depends('JS_STANDALONE') -def js_standalone(value): - if value: - set_config('JS_STANDALONE', '1') - add_old_configure_assignment('JS_STANDALONE', '1') - - -js_option('--disable-js-shell', default=building_js, +js_option('--disable-js-shell', default=js_shell_default, help='Do not build the JS shell') @depends('--disable-js-shell') @@ -36,10 +22,14 @@ def js_shell(value): # SpiderMonkey as a shared library, and how its symbols are exported # ================================================================== -js_option('--disable-shared-js', default=building_js, +@depends(build_project, '--help') +def js_shared_default(build_project, help): + return build_project == 'js' + +js_option('--disable-shared-js', default=js_shared_default, help='Do not create a shared library') -js_option('--disable-export-js', default=building_js, +js_option('--disable-export-js', default=js_shared_default, help='Do not mark JS symbols as DLL exported/visible') @depends('--disable-shared-js', '--disable-export-js') diff --git a/js/src/old-configure.in b/js/src/old-configure.in index 61fa54770d69..39705dfdb633 100644 --- a/js/src/old-configure.in +++ b/js/src/old-configure.in @@ -75,12 +75,18 @@ MOZ_BUILD_ROOT=`pwd -W 2>/dev/null || pwd -P` MOZ_DEFAULT_COMPILER -if test -z "$JS_STANDALONE"; then +if test "$JS_STANDALONE" = no; then autoconfmk=autoconf-js.mk + JS_STANDALONE= #DIST is exported from top-level configure else + JS_STANDALONE=1 + AC_DEFINE(JS_STANDALONE) DIST="$MOZ_BUILD_ROOT/dist" fi +AC_SUBST(JS_STANDALONE) +BUILDING_JS=1 +AC_SUBST(BUILDING_JS) AC_SUBST(autoconfmk) MOZ_ARG_WITH_STRING(gonk-toolchain-prefix, diff --git a/old-configure.in b/old-configure.in index 14a20109ac5d..a65ca67d0d55 100644 --- a/old-configure.in +++ b/old-configure.in @@ -3097,6 +3097,7 @@ if test -n "$MOZ_RUST"; then fi fi +AC_SUBST(MOZ_BUILD_APP) AC_SUBST(MOZ_PHOENIX) AC_SUBST(MOZ_XULRUNNER) AC_SUBST(MOZ_B2G) @@ -3104,6 +3105,8 @@ AC_SUBST(MOZ_MULET) AC_SUBST(MOZ_B2G_VERSION) AC_SUBST(MOZ_B2GDROID) +AC_DEFINE_UNQUOTED(MOZ_BUILD_APP,$MOZ_BUILD_APP) + dnl ======================================================== dnl Ensure Android SDK and build-tools versions depending on dnl mobile target. @@ -7939,7 +7942,7 @@ export RUSTC export MOZILLA_CENTRAL_PATH=$_topsrcdir export STLPORT_CPPFLAGS export STLPORT_LIBS -export JS_STANDALONE= +export JS_STANDALONE=no export DIST export MOZ_LINKER export ZLIB_IN_MOZGLUE