Thu, 22 Jan 2015 13:21:57 +0100
Incorporate requested changes from Mozilla in review:
https://bugzilla.mozilla.org/show_bug.cgi?id=1123480#c6
michael@0 | 1 | # |
michael@0 | 2 | # This Source Code Form is subject to the terms of the Mozilla Public |
michael@0 | 3 | # License, v. 2.0. If a copy of the MPL was not distributed with this |
michael@0 | 4 | # file, You can obtain one at http://mozilla.org/MPL/2.0/. |
michael@0 | 5 | |
michael@0 | 6 | # |
michael@0 | 7 | # Override TARGETS variable so that only static libraries |
michael@0 | 8 | # are specifed as dependencies within rules.mk. |
michael@0 | 9 | # |
michael@0 | 10 | |
michael@0 | 11 | # can't do this in manifest.mn because OS_TARGET isn't defined there. |
michael@0 | 12 | ifeq (,$(filter-out WIN%,$(OS_TARGET))) |
michael@0 | 13 | |
michael@0 | 14 | # don't want the 32 in the shared library name |
michael@0 | 15 | SHARED_LIBRARY = $(OBJDIR)/$(DLL_PREFIX)$(LIBRARY_NAME)$(LIBRARY_VERSION).$(DLL_SUFFIX) |
michael@0 | 16 | IMPORT_LIBRARY = $(OBJDIR)/$(IMPORT_LIB_PREFIX)$(LIBRARY_NAME)$(LIBRARY_VERSION)$(IMPORT_LIB_SUFFIX) |
michael@0 | 17 | |
michael@0 | 18 | RES = $(OBJDIR)/$(LIBRARY_NAME).res |
michael@0 | 19 | RESNAME = $(LIBRARY_NAME).rc |
michael@0 | 20 | |
michael@0 | 21 | ifdef NS_USE_GCC |
michael@0 | 22 | EXTRA_SHARED_LIBS += \ |
michael@0 | 23 | -L$(DIST)/lib \ |
michael@0 | 24 | -L$(NSSUTIL_LIB_DIR) \ |
michael@0 | 25 | -lnssutil3 \ |
michael@0 | 26 | -L$(NSPR_LIB_DIR) \ |
michael@0 | 27 | -lplc4 \ |
michael@0 | 28 | -lplds4 \ |
michael@0 | 29 | -lnspr4\ |
michael@0 | 30 | $(NULL) |
michael@0 | 31 | else # ! NS_USE_GCC |
michael@0 | 32 | EXTRA_SHARED_LIBS += \ |
michael@0 | 33 | $(DIST)/lib/nssutil3.lib \ |
michael@0 | 34 | $(NSPR_LIB_DIR)/$(NSPR31_LIB_PREFIX)plc4.lib \ |
michael@0 | 35 | $(NSPR_LIB_DIR)/$(NSPR31_LIB_PREFIX)plds4.lib \ |
michael@0 | 36 | $(NSPR_LIB_DIR)/$(NSPR31_LIB_PREFIX)nspr4.lib \ |
michael@0 | 37 | $(NULL) |
michael@0 | 38 | endif # NS_USE_GCC |
michael@0 | 39 | |
michael@0 | 40 | else |
michael@0 | 41 | |
michael@0 | 42 | # $(PROGRAM) has NO explicit dependencies on $(EXTRA_SHARED_LIBS) |
michael@0 | 43 | # $(EXTRA_SHARED_LIBS) come before $(OS_LIBS), except on AIX. |
michael@0 | 44 | EXTRA_SHARED_LIBS += \ |
michael@0 | 45 | -L$(DIST)/lib \ |
michael@0 | 46 | -L$(NSSUTIL_LIB_DIR) \ |
michael@0 | 47 | -lnssutil3 \ |
michael@0 | 48 | -L$(NSPR_LIB_DIR) \ |
michael@0 | 49 | -lplc4 \ |
michael@0 | 50 | -lplds4 \ |
michael@0 | 51 | -lnspr4 \ |
michael@0 | 52 | $(NULL) |
michael@0 | 53 | |
michael@0 | 54 | endif |
michael@0 | 55 | |
michael@0 | 56 | |
michael@0 | 57 | # $(PROGRAM) has explicit dependencies on $(EXTRA_LIBS) |
michael@0 | 58 | |
michael@0 | 59 | ifeq ($(OS_TARGET),SunOS) |
michael@0 | 60 | ifeq ($(BUILD_SUN_PKG), 1) |
michael@0 | 61 | # The -R '$ORIGIN' linker option instructs this library to search for its |
michael@0 | 62 | # dependencies in the same directory where it resides. |
michael@0 | 63 | ifeq ($(USE_64), 1) |
michael@0 | 64 | MKSHLIB += -R '$$ORIGIN:/usr/lib/mps/secv1/64:/usr/lib/mps/64' |
michael@0 | 65 | else |
michael@0 | 66 | MKSHLIB += -R '$$ORIGIN:/usr/lib/mps/secv1:/usr/lib/mps' |
michael@0 | 67 | endif |
michael@0 | 68 | else |
michael@0 | 69 | MKSHLIB += -R '$$ORIGIN' |
michael@0 | 70 | endif |
michael@0 | 71 | endif |
michael@0 | 72 | |
michael@0 | 73 | ifeq ($(OS_ARCH), HP-UX) |
michael@0 | 74 | ifneq ($(OS_TEST), ia64) |
michael@0 | 75 | # pa-risc |
michael@0 | 76 | ifeq ($(USE_64), 1) |
michael@0 | 77 | MKSHLIB += +b '$$ORIGIN' |
michael@0 | 78 | endif |
michael@0 | 79 | endif |
michael@0 | 80 | endif |