Bug 1252931 - Remove INSTALL/PP_TARGETS from js/src/*; r=gps
authorMike Shal <mshal@mozilla.com>
Fri, 18 Mar 2016 19:32:45 -0400
changeset 290502 491142a0995b238d872d058a2e61a9872408a0b5
parent 290501 b5d975e3f9824811d93b6eef54279a0875bf3efe
child 290503 f87d50f9757747dc07215b022cb993312306e21b
push id19656
push usergwagner@mozilla.com
push dateMon, 04 Apr 2016 13:43:23 +0000
treeherderb2g-inbound@e99061fde28a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgps
bugs1252931
milestone48.0a1
Bug 1252931 - Remove INSTALL/PP_TARGETS from js/src/*; r=gps MozReview-Commit-ID: Lb0V5x1aP7z
js/src/Makefile.in
js/src/gdb/Makefile.in
js/src/gdb/moz.build
js/src/jsapi-tests/Makefile.in
js/src/jsapi-tests/moz.build
js/src/moz.build
js/src/shell/Makefile.in
js/src/shell/moz.build
--- a/js/src/Makefile.in
+++ b/js/src/Makefile.in
@@ -36,26 +36,16 @@ OS_LDFLAGS += -Wl,-version-script,symver
 
 symverscript: symverscript.in
 	$(call py_action,preprocessor, \
 		-DVERSION='$(subst -,_,$(LIBRARY_NAME))' $< -o $@)
 
 EXTRA_DEPS += symverscript
 endif
 
-export_files = js-config.h
-ifdef HAVE_DTRACE
-export_files += $(CURDIR)/javascript-trace.h
-endif
-
-INSTALL_TARGETS += jsconfig
-jsconfig_FILES = $(export_files)
-jsconfig_DEST = $(DIST)/include
-jsconfig_TARGET := export
-
 include $(topsrcdir)/config/rules.mk
 
 # check_vanilla_allocations.py is tailored to Linux, so only run it there.
 # That should be enough to catch any problems.
 check-vanilla-allocations:
 	$(PYTHON) $(topsrcdir)/config/check_vanilla_allocations.py $(REAL_LIBRARY)
 
 # The "aggressive" variant will likely fail on some compiler/platform
@@ -248,17 +238,17 @@ ETWProvider.res: ETWProvider.rc
 export:: ETWProvider.res
 
 install:: ETWProvider.mof ETWProvider.man
 	$(SYSINSTALL) $^ $(DESTDIR)$(bindir)
 
 endif
 
 ifdef HAVE_DTRACE
-$(CURDIR)/javascript-trace.h: $(srcdir)/devtools/javascript-trace.d
+javascript-trace.h: $(srcdir)/devtools/javascript-trace.d
 	dtrace -x nolibs -h -s $(srcdir)/devtools/javascript-trace.d -o javascript-trace.h.in
 	sed -e 's/if _DTRACE_VERSION/ifdef INCLUDE_MOZILLA_DTRACE/' \
 	    -e '/const/!s/char \*/const char */g' \
 	    javascript-trace.h.in > javascript-trace.h
 
 # We can't automatically generate dependencies on auto-generated headers;
 # we have to list them explicitly.
 $(addsuffix .$(OBJ_SUFFIX),Probes jsinterp jsobj): $(CURDIR)/javascript-trace.h
deleted file mode 100644
--- a/js/src/gdb/Makefile.in
+++ /dev/null
@@ -1,15 +0,0 @@
-# -*- Mode: makefile -*-
-#
-# This Source Code Form is subject to the terms of the Mozilla Public
-# License, v. 2.0. If a copy of the MPL was not distributed with this
-# file, You can obtain one at http://mozilla.org/MPL/2.0/.
-
-# Place a GDB Python auto-load file next to the gdb-tests executable, both
-# in the build directory and in the dist/bin directory.
-PP_TARGETS += GDB_AUTOLOAD
-GDB_AUTOLOAD := gdb-tests-gdb.py.in
-GDB_AUTOLOAD_FLAGS := -Dtopsrcdir=$(abspath $(srcdir)/..)
-
-INSTALL_TARGETS += GDB_INSTALL_AUTOLOAD
-GDB_INSTALL_AUTOLOAD_FILES := $(CURDIR)/gdb-tests-gdb.py
-GDB_INSTALL_AUTOLOAD_DEST := $(DIST)/bin
--- a/js/src/gdb/moz.build
+++ b/js/src/gdb/moz.build
@@ -33,8 +33,12 @@ USE_LIBS += [
     'static:js',
 ]
 
 OS_LIBS += CONFIG['MOZ_ZLIB_LIBS']
 
 # This is intended as a temporary workaround to enable VS2015.
 if CONFIG['_MSC_VER']:
     CXXFLAGS += ['-wd4312']
+
+DEFINES['topsrcdir'] = '%s/js/src' % TOPSRCDIR
+FINAL_TARGET_PP_FILES += ['gdb-tests-gdb.py.in']
+OBJDIR_FILES.js.src.gdb += ['!/dist/bin/gdb-tests-gdb.py']
--- a/js/src/jsapi-tests/Makefile.in
+++ b/js/src/jsapi-tests/Makefile.in
@@ -2,14 +2,8 @@
 #
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 ifdef QEMU_EXE
 MOZ_POST_PROGRAM_COMMAND = $(topsrcdir)/build/qemu-wrap --qemu $(QEMU_EXE) --libdir $(CROSS_LIB)
 endif
-
-# Place a GDB Python auto-load file next to the jsapi-tests executable in
-# the build directory.
-PP_TARGETS += JSAPI_TESTS_AUTOLOAD
-JSAPI_TESTS_AUTOLOAD := jsapi-tests-gdb.py.in
-JSAPI_TESTS_AUTOLOAD_FLAGS := -Dtopsrcdir=$(abspath $(srcdir)/..)
--- a/js/src/jsapi-tests/moz.build
+++ b/js/src/jsapi-tests/moz.build
@@ -128,8 +128,11 @@ USE_LIBS += [
     'static:js',
 ]
 
 OS_LIBS += CONFIG['MOZ_ZLIB_LIBS']
 
 # This is intended as a temporary workaround to enable VS2015.
 if CONFIG['_MSC_VER']:
     CXXFLAGS += ['-wd4312']
+
+DEFINES['topsrcdir'] = '%s/js/src' % TOPSRCDIR
+OBJDIR_PP_FILES.js.src['jsapi-tests'] += ['jsapi-tests-gdb.py.in']
--- a/js/src/moz.build
+++ b/js/src/moz.build
@@ -72,20 +72,26 @@ if not CONFIG['JS_STANDALONE']:
         '../../config/autoconf-js.mk',
         '../../config/emptyvars-js.mk',
     ]
 
 CONFIGURE_DEFINE_FILES += [
     'js-config.h',
 ]
 
+if CONFIG['HAVE_DTRACE']:
+    GENERATED_FILES += ['javascript-trace.h']
+
+    EXPORTS += ['!javascript-trace.h']
+
 # Changes to internal header files, used externally, massively slow down
 # browser builds.  Don't add new files here unless you know what you're
 # doing!
 EXPORTS += [
+    '!js-config.h',
     'js.msg',
     'jsalloc.h',
     'jsapi.h',
     'jsbytecode.h',
     'jsclist.h',
     'jscpucfg.h',
     'jsfriendapi.h',
     'jsprf.h',
--- a/js/src/shell/Makefile.in
+++ b/js/src/shell/Makefile.in
@@ -3,26 +3,16 @@
 # This Source Code Form is subject to the terms of the Mozilla Public
 # License, v. 2.0. If a copy of the MPL was not distributed with this
 # file, You can obtain one at http://mozilla.org/MPL/2.0/.
 
 ifdef QEMU_EXE
 MOZ_POST_PROGRAM_COMMAND = $(topsrcdir)/build/qemu-wrap --qemu $(QEMU_EXE) --libdir $(CROSS_LIB)
 endif
 
-# Place a GDB Python auto-load file next to the shell executable, both in
-# the build directory and in the dist/bin directory.
-PP_TARGETS += SHELL_AUTOLOAD
-SHELL_AUTOLOAD := js-gdb.py.in
-SHELL_AUTOLOAD_FLAGS := -Dtopsrcdir=$(abspath $(srcdir)/..)
-
-INSTALL_TARGETS += SHELL_INSTALL_AUTOLOAD
-SHELL_INSTALL_AUTOLOAD_FILES := $(CURDIR)/js-gdb.py
-SHELL_INSTALL_AUTOLOAD_DEST := $(DIST)/bin
-
 include $(topsrcdir)/config/rules.mk
 
 # People expect the js shell to wind up in the top-level JS dir.
 libs::
 	$(INSTALL) $(IFLAGS2) $(PROGRAM) ..
 
 GARBAGE += ../$(PROGRAM)
 
--- a/js/src/shell/moz.build
+++ b/js/src/shell/moz.build
@@ -43,8 +43,14 @@ shellmoduleloader.script = '../builtin/e
 shellmoduleloader.inputs = [
     '../js.msg',
     'ModuleLoader.js',
 ]
 
 # This is intended as a temporary workaround to enable VS2015.
 if CONFIG['_MSC_VER']:
     CXXFLAGS += ['-wd4312']
+
+# Place a GDB Python auto-load file next to the shell executable, both in
+# the build directory and in the dist/bin directory.
+DEFINES['topsrcdir'] = '%s/js/src' % TOPSRCDIR
+FINAL_TARGET_PP_FILES += ['js-gdb.py.in']
+OBJDIR_FILES.js.src.shell += ['!/dist/bin/js-gdb.py']