First pass at getting shared libraries on AIX properly built.
This commit is contained in:
parent
45f1d32bf1
commit
5c410fa0b9
@ -7,7 +7,7 @@
|
||||
#
|
||||
#
|
||||
# IDENTIFICATION
|
||||
# $Header: /cvsroot/pgsql/src/Attic/Makefile.global,v 1.73 1996/11/18 16:32:53 momjian Exp $
|
||||
# $Header: /cvsroot/pgsql/src/Attic/Makefile.global,v 1.74 1996/11/23 09:50:34 bryanh Exp $
|
||||
#
|
||||
# NOTES
|
||||
# Essentially all Postgres make files include this file and use the
|
||||
@ -342,15 +342,20 @@ CFLAGS_BE= -qchars=signed -qmaxmem=4000
|
||||
|
||||
EXPSUFF= .exp
|
||||
|
||||
POSTGRES_EXP= $(SRCDIR)/backend/postgres$(EXPSUFF)
|
||||
|
||||
MKLDEXPORT=$(SRCDIR)/backend/port/aix/mkldexport.sh
|
||||
|
||||
%$(EXPSUFF): %.o
|
||||
$(MKLDEXPORT) $< `pwd` > $@
|
||||
|
||||
%.so: %.o %$(EXPSUFF)
|
||||
@echo The link stage here:
|
||||
$(POSTGRES_EXP):
|
||||
$(MAKE) -C $(SRCDIR)/backend postgres.exp
|
||||
|
||||
%.so: %.o %$(EXPSUFF) $(POSTGRES_EXP)
|
||||
@echo Making share library $@ from $*.o, $*$(EXPSUFF), and postgres.exp
|
||||
$(LD) -H512 -T512 -o $@ -e _nostart \
|
||||
-bI:$(LIBDIR)/postgres$(EXPSUFF) -bE:$*$(EXPSUFF) \
|
||||
-bI:$(POSTGRES_EXP) -bE:$*$(EXPSUFF) \
|
||||
$*.o -lm -lc 2>/dev/null
|
||||
endif
|
||||
|
||||
|
@ -34,7 +34,7 @@
|
||||
#
|
||||
#
|
||||
# IDENTIFICATION
|
||||
# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.16 1996/11/18 02:23:41 bryanh Exp $
|
||||
# $Header: /cvsroot/pgsql/src/backend/Makefile,v 1.17 1996/11/23 09:51:57 bryanh Exp $
|
||||
#
|
||||
#-------------------------------------------------------------------------
|
||||
|
||||
@ -53,7 +53,13 @@ ifdef TIOGA
|
||||
OBJS += tioga/SUBSYS.o
|
||||
endif
|
||||
|
||||
all: postgres global1.bki.source local1_template1.bki.source
|
||||
ifeq ($(MAKE_EXPORTS), true)
|
||||
EXP = postgres$(EXPSUFF)
|
||||
else
|
||||
EXP =
|
||||
endif
|
||||
|
||||
all: postgres $(EXP) global1.bki.source local1_template1.bki.source
|
||||
|
||||
postgres: postgres_group1 postgres_group2 postgres_group3 postgres_group4
|
||||
$(CC) $(LDFLAGS) -o postgres $(OBJS) $(LDADD)
|
||||
@ -89,6 +95,11 @@ global1.bki.source local1_template1.bki.source:
|
||||
$(MAKE) -C catalog $@
|
||||
cp catalog/$@ .
|
||||
|
||||
# The postgres.o target is needed by the rule in Makefile.global that
|
||||
# creates the exports file when MAKE_EXPORTS = true.
|
||||
postgres.o: $(OBJS)
|
||||
$(CC) $(LDFLAGS) -r -o postgres.o $(OBJS) $(LDADD)
|
||||
|
||||
|
||||
############################################################################
|
||||
# The following targets are specified in make commands that appear in the
|
||||
@ -168,25 +179,25 @@ endif
|
||||
# and (2) the parameters of a database system should be set at initdb time,
|
||||
# not at postgres build time.
|
||||
|
||||
D_LIBDIR = $(DESTDIR)$(LIBDIR)
|
||||
D_BINDIR = $(DESTDIR)$(BINDIR)
|
||||
|
||||
install: $(D_LIBDIR) $(D_BINDIR) $(HEADERDIR) postgres fmgr.h\
|
||||
install: $(LIBDIR) $(BINDIR) $(HEADERDIR) postgres $(EXP) fmgr.h\
|
||||
global1.bki.source local1_template1.bki.source \
|
||||
libpq/pg_hba.conf.sample
|
||||
libpq/pg_hba.conf.sample
|
||||
|
||||
$(INSTALL) $(INSTL_EXE_OPTS) postgres $(D_BINDIR)/postgres
|
||||
@rm -f $(D_BINDIR)/postmaster
|
||||
cd $(D_BINDIR); ln -s postgres postmaster
|
||||
$(INSTALL) $(INSTL_EXE_OPTS) postgres $(BINDIR)/postgres
|
||||
ifeq ($(MAKE_EXPORTS), true)
|
||||
$(INSTALL) $(INSTLOPTS) postgres$(EXPSUFF) $(LIBDIR)/postgres$(EXPSUFF)
|
||||
endif
|
||||
@rm -f $(BINDIR)/postmaster
|
||||
cd $(BINDIR); ln -s postgres postmaster
|
||||
$(INSTALL) $(INSTLOPTS) fmgr.h $(HEADERDIR)/fmgr.h
|
||||
$(INSTALL) $(INSTLOPTS) global1.bki.source \
|
||||
$(D_LIBDIR)/global1.bki.source
|
||||
$(LIBDIR)/global1.bki.source
|
||||
$(INSTALL) $(INSTLOPTS) local1_template1.bki.source \
|
||||
$(D_LIBDIR)/local1_template1.bki.source
|
||||
$(LIBDIR)/local1_template1.bki.source
|
||||
$(INSTALL) $(INSTLOPTS) libpq/pg_hba.conf.sample \
|
||||
$(D_LIBDIR)/pg_hba.conf.sample
|
||||
$(LIBDIR)/pg_hba.conf.sample
|
||||
|
||||
$(D_BINDIR) $(D_LIBDIR) $(HEADERDIR):
|
||||
$(BINDIR) $(LIBDIR) $(HEADERDIR):
|
||||
mkdir $@
|
||||
|
||||
#############################################################################
|
||||
|
Loading…
x
Reference in New Issue
Block a user