# THIS FILE WAS AUTOMATICALLY GENERATED. DO NOT MODIFY BY HAND.
DEPTH := ../../..
topobjdir := /jenkins/jobs/oi-userland/workspace/components/web/firefox/build/amd64
topsrcdir := /jenkins/jobs/oi-userland/workspace/components/web/firefox/firefox-147.0.3
srcdir := /jenkins/jobs/oi-userland/workspace/components/web/firefox/firefox-147.0.3/js/src/build
srcdir_rel := ../../../../../firefox-147.0.3/js/src/build
relativesrcdir := js/src/build
include $(DEPTH)/config/autoconf.mk
# -*- 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

# 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)

# Install the profiling category list into both js/ and the root include
# directory, for use with both js-specific and base profilers.
install:: ../../../mozglue/baseprofiler/public/ProfilingCategoryList.h
	$(SYSINSTALL) $^ $(DESTDIR)$(includedir)/$(JS_LIBRARY_NAME)/js
	$(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)/$(notdir $(SHARED_LIBRARY))) $(DESTDIR)$(libdir)/$(notdir $(SHARED_LIBRARY))
endif
endif
ifneq (,$(IMPORT_LIBRARY))
ifneq ($(IMPORT_LIBRARY),$(SHARED_LIBRARY))
	$(SYSINSTALL) $(IMPORT_LIBRARY) $(DESTDIR)$(libdir)
endif
endif

include $(topsrcdir)/config/recurse.mk
