Bug 1407468 - Only build js/src when building toolkit. r=mshal
authorMike Hommey <mh+mozilla@glandium.org>
Thu, 05 Oct 2017 11:30:18 +0900
changeset 680001 e07a025fdc8f27af71040ec96e681b19b1039555
parent 680000 42d708dc85fcdbca80deeaedd792396401d2f022
child 680002 84946a59ea8a5fae6d77053c5dc8b94ecf2e16e2
push id84367
push userbmo:mh+mozilla@glandium.org
push dateFri, 13 Oct 2017 09:34:29 +0000
reviewersmshal
bugs1407468
milestone58.0a1
Bug 1407468 - Only build js/src when building toolkit. r=mshal
moz.build
old-configure.in
--- a/moz.build
+++ b/moz.build
@@ -107,17 +107,18 @@ if not CONFIG['JS_STANDALONE']:
     GENERATED_FILES['buildid.h'].script = 'build/variables.py:buildid_header'
     GENERATED_FILES['source-repo.h'].script = 'build/variables.py:source_repo_header'
 
     DIRS += [
         'build',
         'tools',
     ]
 
-if CONFIG['COMPILE_ENVIRONMENT']:
+if CONFIG['COMPILE_ENVIRONMENT'] and (CONFIG['MOZ_WIDGET_TOOLKIT'] or
+                                      CONFIG['JS_STANDALONE']):
     DIRS += ['js/src']
 
 DIRS += [
     'config/external/fdlibm',
     'config/external/nspr',
     'config/external/zlib',
     'memory',
     'mfbt',
--- a/old-configure.in
+++ b/old-configure.in
@@ -5027,17 +5027,17 @@ if test -n "$_subconfigure_subdir"; then
   srcdir="$srcdir/.."
   _save_ac_configure_args="$ac_configure_args"
   ac_configure_args="$_subconfigure_config_args"
   AC_OUTPUT_SUBDIRS_NOW("$_subconfigure_subdir",$cache_file)
   ac_configure_args="$_save_ac_configure_args"
   srcdir="$_save_srcdir"
 fi
 
-if test "$COMPILE_ENVIRONMENT"; then
+if test "$COMPILE_ENVIRONMENT" -a "$MOZ_WIDGET_TOOLKIT"; then
 
 export WRAP_LDFLAGS
 
 dnl ========================================================
 dnl = Setup a nice relatively clean build environment for
 dnl = sub-configures.
 dnl ========================================================
 CC="$_SUBDIR_CC"