зеркало из https://github.com/mozilla/pjs.git
Move map file processing definitions back into base .mk files.
setup up map files so the can be switched on simply by adding a directive to manifest.mn.
This commit is contained in:
Родитель
c954967140
Коммит
a9fdcd7596
|
@ -72,3 +72,9 @@ endif
|
|||
AIX_WRAP = $(DIST)/lib/aixwrap.o
|
||||
AIX_TMP = $(OBJDIR)/_aix_tmp.o
|
||||
OS_LIBS += -lsvld
|
||||
ifdef MAPFILE
|
||||
EXPORT_RULES = -bexport:$(MAPFILE)
|
||||
endif
|
||||
PROCESS_MAP_FILE = grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' > $@
|
||||
|
||||
|
|
|
@ -37,9 +37,14 @@
|
|||
include $(CORE_DEPTH)/coreconf/AIX.mk
|
||||
|
||||
OS_CFLAGS += -DAIX4_2
|
||||
DSO_LDOPTS = -brtl -bM:SRE -bnoentry $(EXPORT_RULES)
|
||||
DSO_LDOPTS = -brtl -bM:SRE -bnoentry
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS) -lsvld -L/usr/lpp/xlC/lib -lc -lm
|
||||
|
||||
OS_LIBS += -L/usr/lpp/xlC/lib -lc -lm
|
||||
EXPORT_RULES = -bexpall
|
||||
ifdef MAPFILE
|
||||
DSO_LDOPTS += -bexport:$(MAPFILE)
|
||||
else
|
||||
DSO_LDOPTS += -bexpall
|
||||
endif
|
||||
|
||||
|
||||
|
|
|
@ -44,9 +44,12 @@ ifeq ($(USE_64), 1)
|
|||
export OBJECT_MODE
|
||||
endif
|
||||
OS_CFLAGS += -DAIX4_3
|
||||
DSO_LDOPTS = -brtl -bM:SRE -bnoentry $(EXPORT_RULES)
|
||||
DSO_LDOPTS = -brtl -bM:SRE -bnoentry
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS) -lsvld -L/usr/lpp/xlC/lib -lc -lm
|
||||
|
||||
OS_LIBS += -L/usr/lpp/xlC/lib -lc -lm
|
||||
EXPORT_RULES = -bexpall
|
||||
|
||||
ifdef MAPFILE
|
||||
DSO_LDOPTS += -bexport:$(MAPFILE)
|
||||
else
|
||||
DSO_LDOPTS += -bexpall
|
||||
endif
|
||||
|
|
|
@ -77,6 +77,11 @@ DSO_LDOPTS += -Wl,-R$(LIBRUNPATH)
|
|||
endif
|
||||
|
||||
MKSHLIB = $(CC) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
G++INCLUDES = -I/usr/include/g++
|
||||
|
||||
|
|
|
@ -73,6 +73,11 @@ DSO_LDOPTS = -Bshareable
|
|||
DSO_LDFLAGS =
|
||||
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
G++INCLUDES = -I/usr/include/g++
|
||||
|
||||
|
|
|
@ -63,6 +63,11 @@ endif
|
|||
LDFLAGS = -z -Wl,+s
|
||||
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
MKSHLIB += -c $(MAPFILE)
|
||||
endif
|
||||
PROCESS_MAP_FILE = grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' -e 's,^,+e ,' > $@
|
||||
|
||||
DSO_LDOPTS = -b +h $(notdir $@)
|
||||
DSO_LDFLAGS =
|
||||
|
|
|
@ -101,6 +101,11 @@ ifeq ($(USE_N32),1)
|
|||
endif
|
||||
|
||||
MKSHLIB += $(LD) $(SHLIB_LD_OPTS) -shared -soname $(@:$(OBJDIR)/%.so=%.so)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
DSO_LDOPTS = -elf -shared -all
|
||||
|
||||
|
|
|
@ -92,6 +92,11 @@ ifeq ($(OS_RELEASE),2.0)
|
|||
ifdef BUILD_OPT
|
||||
OPTIMIZER = -O2
|
||||
endif
|
||||
ifdef MAPFILE
|
||||
MKSHLIB += -Wl,--version-script,$(MAPFILE)
|
||||
endif
|
||||
PROCESS_MAP_FILE = grep -v ';-' $(LIBRARY_NAME).def | \
|
||||
sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $@
|
||||
endif
|
||||
|
||||
ifeq ($(USE_PTHREADS),1)
|
||||
|
|
|
@ -66,6 +66,11 @@ endif
|
|||
MKSHLIB += $(LD) $(DSO_LDOPTS)
|
||||
#DSO_LDOPTS += -G -z defs
|
||||
DSO_LDOPTS += -G
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
CPU_ARCH = x86
|
||||
ARCH = ncr
|
||||
|
|
|
@ -49,6 +49,11 @@ CCC = g++
|
|||
endif
|
||||
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
RANLIB = /bin/true
|
||||
|
||||
|
|
|
@ -74,6 +74,12 @@ DSO_LDOPTS += -Wl,-R$(LIBRUNPATH)
|
|||
endif
|
||||
|
||||
MKSHLIB = $(CC) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
|
||||
G++INCLUDES = -I/usr/include/g++
|
||||
|
||||
|
|
|
@ -86,6 +86,12 @@ DSO_LDOPTS = -Zomf -Zdll -Zmt -Zcrtdll -Zlinker /NOO
|
|||
# DLL_SUFFIX = .dll
|
||||
SHLIB_LDSTARTFILE =
|
||||
SHLIB_LDENDFILE =
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = copy $(LIBRARY_NAME).def $@
|
||||
|
||||
endif #NO_SHARED_LIB
|
||||
|
||||
OS_CFLAGS = -Wall -W -Wno-unused -Wpointer-arith -Wcast-align -Zmtd -Zomf -Zmt -DDEBUG -DDEBUG_wintrinh -DTRACING -g
|
||||
|
|
|
@ -63,4 +63,10 @@ endif
|
|||
|
||||
# The command to build a shared library on OSF1.
|
||||
MKSHLIB += ld -shared -expect_unresolved "*" -soname $(notdir $@)
|
||||
ifdef MAPFILE
|
||||
MKSHLIB += -hidden -input $(MAPFILE)
|
||||
endif
|
||||
PROCESS_MAP_FILE = grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' -e 's,^,-exported_symbol ,' > $@
|
||||
|
||||
DSO_LDOPTS += -shared
|
||||
|
|
|
@ -54,3 +54,9 @@ XCFLAGS += $(OPTIMIZER)
|
|||
|
||||
# The command to build a shared library in POSIX on OpenVMS.
|
||||
MKSHLIB = vmsld_psm OBJDIR=$(OBJDIR) $(OPTIMIZER)
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = copy $(LIBRARY_NAME).def $@
|
||||
|
||||
|
|
|
@ -65,6 +65,11 @@ else
|
|||
MKSHLIB += -G -h $(@:$(OBJDIR)/%.so=%.so)
|
||||
DSO_LDOPTS += -G -W l,-Blargedynsym
|
||||
endif
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
NOSUCHFILE = /sni-rm-f-sucks
|
||||
ODD_CFLAGS += -DSVR4 -DSNI -DRELIANTUNIX
|
||||
|
|
|
@ -73,6 +73,11 @@ I2_LOCALE = i2
|
|||
LOC_LIB_DIR = /usr/lib/X11
|
||||
NOSUCHFILE = /solaris-rm-f-sucks
|
||||
BSDECHO = /bin/echo
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
#
|
||||
# These defines are for building unix plugins
|
||||
|
|
|
@ -132,6 +132,14 @@ endif
|
|||
NOMD_OS_CFLAGS += $(DSO_CFLAGS) $(OS_DEFINES) $(SOL_CFLAGS)
|
||||
|
||||
MKSHLIB = $(LD) $(DSO_LDOPTS)
|
||||
ifdef MAPFILE
|
||||
MKSHLIB += -M $(MAPFILE)
|
||||
endif
|
||||
PROCESS_MAP_FILE = grep -v ';-' $(LIBRARY_NAME).def | \
|
||||
sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $@
|
||||
|
||||
|
||||
|
||||
|
||||
# ld options:
|
||||
# -G: produce a shared object
|
||||
|
|
|
@ -49,3 +49,9 @@ DSO_LDOPTS += -G
|
|||
CPU_ARCH = x86
|
||||
ARCH = sco
|
||||
NOSUCHFILE = /solaris-rm-f-sucks
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = cp $(LIBRARY_NAME).def $@
|
||||
|
||||
|
|
|
@ -109,6 +109,12 @@ OS_DLL_OPTION = CASEEXACT
|
|||
OS_DLLFLAGS =
|
||||
OS_LIBS =
|
||||
W16_EXPORTS = #
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = copy $(LIBRARY_NAME).def $@
|
||||
|
||||
|
||||
#
|
||||
# The following is NOT needed for the NSPR 2.0 library.
|
||||
|
|
|
@ -91,6 +91,12 @@ else
|
|||
endif
|
||||
|
||||
DEFINES += -DWIN32
|
||||
ifdef MAPFILE
|
||||
# Add LD options to restrict exported symbols to those in the map file
|
||||
endif
|
||||
# Change PROCESS to put the mapfile in the correct format for this platform
|
||||
PROCESS_MAP_FILE = copy $(LIBRARY_NAME).def $@
|
||||
|
||||
|
||||
#
|
||||
# The following is NOT needed for the NSPR 2.0 library.
|
||||
|
|
|
@ -377,27 +377,7 @@ endif
|
|||
|
||||
$(MAPFILE): $(LIBRARY_NAME).def
|
||||
@$(MAKE_OBJDIR)
|
||||
ifeq ($(OS_ARCH),SunOS)
|
||||
grep -v ';-' $(LIBRARY_NAME).def | \
|
||||
sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $@
|
||||
endif
|
||||
ifeq ($(OS_ARCH),Linux)
|
||||
grep -v ';-' $(LIBRARY_NAME).def | \
|
||||
sed -e 's,;+,,' -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,;,' > $@
|
||||
endif
|
||||
ifeq ($(OS_ARCH),AIX)
|
||||
grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' > $@
|
||||
endif
|
||||
ifeq ($(OS_ARCH), HP-UX)
|
||||
grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' -e 's,^,+e ,' > $@
|
||||
endif
|
||||
ifeq ($(OS_ARCH), OSF1)
|
||||
grep -v ';+' $(LIBRARY_NAME).def | grep -v ';-' | \
|
||||
sed -e 's; DATA ;;' -e 's,;;,,' -e 's,;.*,,' -e 's,^,-exported_symbol ,' > $@
|
||||
endif
|
||||
|
||||
$(PROCESS_MAP_FILE)
|
||||
|
||||
|
||||
$(OBJDIR)/$(PROG_PREFIX)%$(PROG_SUFFIX): $(OBJDIR)/$(PROG_PREFIX)%$(OBJ_SUFFIX)
|
||||
|
|
Загрузка…
Ссылка в новой задаче