diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-28 14:29:10 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-28 14:29:10 +0000 |
commit | 2aa4a82499d4becd2284cdb482213d541b8804dd (patch) | |
tree | b80bf8bf13c3766139fbacc530efd0dd9d54394c /js/src/build/Makefile.in | |
parent | Initial commit. (diff) | |
download | firefox-upstream.tar.xz firefox-upstream.zip |
Adding upstream version 86.0.1.upstream/86.0.1upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'js/src/build/Makefile.in')
-rw-r--r-- | js/src/build/Makefile.in | 87 |
1 files changed, 87 insertions, 0 deletions
diff --git a/js/src/build/Makefile.in b/js/src/build/Makefile.in new file mode 100644 index 0000000000..8548eb2584 --- /dev/null +++ b/js/src/build/Makefile.in @@ -0,0 +1,87 @@ +# -*- 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/. + +include $(topsrcdir)/config/rules.mk + +ifdef NM +# check_vanilla_allocations.py is tailored to Linux, so only run it there. +# That should be enough to catch any problems. +check-vanilla-allocations: + $(PYTHON3) $(topsrcdir)/config/check_vanilla_allocations.py $(REAL_LIBRARY) + +# The "aggressive" variant will likely fail on some compiler/platform +# combinations, but is worth running by hand every once in a while. +check-vanilla-allocations-aggressive: + $(PYTHON3) $(topsrcdir)/config/check_vanilla_allocations.py --aggressive $(REAL_LIBRARY) + +check:: check-vanilla-allocations +endif + +$(LIBRARY_NAME).pc: js.pc + cp $^ $@ + +# Install versioned file, for parallel installability in Linux distributions +install:: $(LIBRARY_NAME).pc + cp $^ $(JS_LIBRARY_NAME).pc + $(SYSINSTALL) $(JS_LIBRARY_NAME).pc $(DESTDIR)$(libdir)/pkgconfig + +install:: ../js-config.h + $(SYSINSTALL) $^ $(DESTDIR)$(includedir)/$(JS_LIBRARY_NAME) + +###################################################### +# BEGIN SpiderMonkey header installation +# +# Mozilla/Gecko/Firefox mostly doesn't concern itself with defining a sensible +# install target, because it's shipping primarily packaged builds. And even if +# it did, those builds wouldn't really have reason to include header files. So +# we have to install public headers ourselves, rather than using something from +# config/rules.mk or similar. +# +# The overall directory structure of the installed headers looks like so: +# +# $(includedir)/ +# $(JS_LIBRARY_NAME)/ +# jsapi.h, jspubtd.h, etc. (all of EXPORTS) +# js/ +# js/public/* headers (all are public) +# ds/ +# js/src/ds/* public headers +# gc/ +# js/src/gc/* public headers +# mozilla/ +# mfbt headers +# + +install:: + $(call py_action,process_install_manifest,$(if $(filter copy,$(NSDISTMODE)),--no-symlinks )--track install_dist_include.track --no-symlinks $(DESTDIR)$(includedir)/$(JS_LIBRARY_NAME) $(DEPTH)/_build_manifests/install/dist_include) + +# +# END SpiderMonkey header installation +############################################# + +# Install versioned script, for parallel installability in Linux distributions +install:: js-config + cp $^ js$(MOZJS_MAJOR_VERSION)-config + $(SYSINSTALL) js$(MOZJS_MAJOR_VERSION)-config $(DESTDIR)$(bindir) + +# Use install_name_tool to set the install_name properly for standalone +# installed libraries on macOS +install:: $(REAL_LIBRARY) $(SHARED_LIBRARY) $(IMPORT_LIBRARY) +ifneq (,$(REAL_LIBRARY)) + $(SYSINSTALL) $(REAL_LIBRARY) $(DESTDIR)$(libdir) + mv -f $(DESTDIR)$(libdir)/$(REAL_LIBRARY) $(subst $(STATIC_LIBRARY_NAME),$(LIBRARY_NAME),$(DESTDIR)$(libdir)/$(REAL_LIBRARY)) +endif +ifneq (,$(SHARED_LIBRARY)) + $(SYSINSTALL) $(SHARED_LIBRARY) $(DESTDIR)$(libdir) +ifeq ($(OS_ARCH),Darwin) + install_name_tool -id $(abspath $(libdir)/$(SHARED_LIBRARY)) $(DESTDIR)$(libdir)/$(SHARED_LIBRARY) +endif +endif +ifneq (,$(IMPORT_LIBRARY)) +ifneq ($(IMPORT_LIBRARY),$(SHARED_LIBRARY)) + $(SYSINSTALL) $(IMPORT_LIBRARY) $(DESTDIR)$(libdir) +endif +endif |