]> git.ipfire.org Git - thirdparty/postgresql.git/commitdiff
Remove port specific Makefile 'targets' (ie. shared libraries) from
authorMarc G. Fournier <scrappy@hub.org>
Sat, 12 Apr 1997 10:33:10 +0000 (10:33 +0000)
committerMarc G. Fournier <scrappy@hub.org>
Sat, 12 Apr 1997 10:33:10 +0000 (10:33 +0000)
Makefile.global and move them to seperate 'include' makefiles

Over time, should become even more port specific:

ie. Makefile.BSD44_derived should be broken down into netbsd/freebsd
specific ports

14 files changed:
src/Makefile.global.in
src/makefiles/Makefile.BSD44_derived [new file with mode: 0644]
src/makefiles/Makefile.aix [new file with mode: 0644]
src/makefiles/Makefile.alpha [new file with mode: 0644]
src/makefiles/Makefile.dgux [new file with mode: 0644]
src/makefiles/Makefile.hpux [new file with mode: 0644]
src/makefiles/Makefile.i386_solaris [new file with mode: 0644]
src/makefiles/Makefile.irix5 [new file with mode: 0644]
src/makefiles/Makefile.linux [new file with mode: 0644]
src/makefiles/Makefile.sparc_solaris [new file with mode: 0644]
src/makefiles/Makefile.sunos4 [new file with mode: 0644]
src/makefiles/Makefile.svr4 [new file with mode: 0644]
src/makefiles/Makefile.ultrix4 [new file with mode: 0644]
src/makefiles/Makefile.univel [new file with mode: 0644]

index a3f3d0e465c12e5660429d30288eb11c194d4e42..e5efb1eed142bf18df1628c7e7d2706a8dbe717b 100644 (file)
@@ -7,7 +7,7 @@
 #
 #
 # IDENTIFICATION
-#    $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.19 1997/04/04 11:21:39 scrappy Exp $
+#    $Header: /cvsroot/pgsql/src/Makefile.global.in,v 1.20 1997/04/12 10:32:03 scrappy Exp $
 #
 # NOTES
 #    Essentially all Postgres make files include this file and use the 
@@ -227,16 +227,6 @@ DASH_N= @DASH_N@
 BACKSLASH_C= @BACKSLASH_C@ 
 
 
-##############################################################################
-#
-# Customization.
-#
-# This includes your local customizations if Makefile.custom exists
-# in the source directory.  This file doesn't exist in the original
-# distribution so that it doesn't get overwritten when you upgrade.
-ifneq ($(wildcard $(SRCDIR)/Makefile.custom), )
-include $(SRCDIR)/Makefile.custom
-endif
 
 #-------------------------------------------------------------
 # See the subdirectory template for default settings for these
@@ -251,171 +241,17 @@ CFLAGS_SL= @SHARED_LIB@
 LDFLAGS= @LDFLAGS@ @LIBS@
 DLSUFFIX= @DLSUFFIX@
 
-#----------------------------------------------------------------------
-ifeq ($(PORTNAME), BSD44_derived)
-%.so: %.o
-       $(LD) -x -r -o $<.obj $<
-       @echo building shared object $@
-       @rm -f $@.pic
-       @${AR} cq $@.pic `lorder $<.obj | tsort`
-       ${RANLIB} $@.pic
-       @rm -f $@
-       $(LD) -x -Bshareable -Bforcearchive \
-         -o $@ $@.pic
-endif
-
-#--------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), aix)
-
-# MAKE_EXPORTS is required for svr4 loaders that want a file of
-# symbol names to tell them what to export/import.
-MAKE_EXPORTS= true
-
-EXPSUFF= .exp
-
-POSTGRES_EXP= $(SRCDIR)/backend/postgres$(EXPSUFF)
-
-MKLDEXPORT=$(SRCDIR)/backend/port/aix/mkldexport.sh
-
-%$(EXPSUFF):  %.o
-       $(MKLDEXPORT) $< `pwd` > $@
-
-$(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:$(POSTGRES_EXP) -bE:$*$(EXPSUFF) \
-         $*.o @MATH_LIB@ -lc 2>/dev/null
-endif
-
-#---------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), alpha)
-%.so:  %.o
-       $(LD) -shared -expect_unresolved '*' -o $@ $<
-endif
-
-#--------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), dgux)
-%.so: %.o
-       $(CC) -shared -o $@ $<
-endif
-
-#----------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), hpux)
-
-#ifdef ENFORCE_ALIGNMENT
-#   CFLAGS_BE= -DNOFIXADE
-#else
-#   HPUX_VERS:= $(shell uname -r)
-#   HPUX_MAJOR= ${HPUX_VERS:R:E}
-#   HPUX_MINOR= ${HPUX_VERS:E}
-#   ifeq ($(HPUX_MAJOR), 08)
-#      CFLAGS_BE+= +u -DHP_S500_ALIGN
-#      LDFLAGS_BE+= +u
-#   else
-#   ifeq ($(HPUX_MAJOR), 09)
-#      ifeq ($(CC), cc)
-#         CFLAGS_BE+= +u4 
-#         LDFLAGS_BE+= +u4
-#      endif
-#   endif
-#   endif
-#endif
-
-%.sl: %.o
-       $(LD) -b -o $@ $<
-
-endif
-
-#--------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), i386_solaris)
-%.so: %.o
-       $(LD) -G -Bdynamic -o $@ $<
-endif
-
-#----------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), irix5)
-
-# RANLIB is not used on IRIX 5
-RANLIB= touch
-
-%.so: %.o
-       $(LD) -G -Bdynamic -o $@ $< $(LDFLAGS)
-
-endif
-
-#---------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), linux)
-ifdef LINUX_ELF
-LDFLAGS+= -rdynamic
-endif
-MK_NO_LORDER= true
-
-%.so: %.o
-       $(CC) -shared -o $@ $<
-
-endif
-
-#---------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), sunos4)
-%.so: %.o
-       $(LD) -dc -dp -Bdynamic -o $@ $<
-endif
-
-#----------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), sparc_solaris)
-%.so: %.o
-       $(LD) -G -Bdynamic -o $@ $<
-endif
-
-#-----------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), svr4)
-# MAKE_EXPORTS is required for svr4 loaders that want a file of
-# symbol names to tell them what to export/import.
-MAKE_EXPORTS= true
-
-LDFLAGS+= /usr/ucblib/libucb.a -LD-Blargedynsym
-
-%.so: %.o
-       $(LD) -G -Bdynamic -o $@ $<
-
-endif
-
-#---------------------------------------------------------------------------
-
-ifeq ($(PORTNAME), ultrix4)
-# install creates intermediate directories
-NO_BEFOREINSTL= true
-endif
-
-
-#-----------------------------------------------------------------------------
+include $(SRCDIR)/Makefile.port
 
+##############################################################################
 #
-#      The univel port is almost guaranteed NOT to work yet.
+# Customization.
 #
-ifeq ($(PORTNAME), univel)
-# MAKE_EXPORTS is required for svr4 loaders that want a file of
-# symbol names to tell them what to export/import.
-#MAKE_EXPORTS= true
-
-%.so: %.o
-       $(LD) -G -Bdynamic -o $@ $<
-
-INSTALL= /usr/ucb/install
-
+# This includes your local customizations if Makefile.custom exists
+# in the source directory.  This file doesn't exist in the original
+# distribution so that it doesn't get overwritten when you upgrade.
+ifneq ($(wildcard $(SRCDIR)/Makefile.custom), )
+include $(SRCDIR)/Makefile.custom
 endif
 
 # This goes here so that customization in Makefile.custom is effective
diff --git a/src/makefiles/Makefile.BSD44_derived b/src/makefiles/Makefile.BSD44_derived
new file mode 100644 (file)
index 0000000..1c17504
--- /dev/null
@@ -0,0 +1,9 @@
+%.so: %.o
+       $(LD) -x -r -o $<.obj $<
+       @echo building shared object $@
+       @rm -f $@.pic
+       @${AR} cq $@.pic `lorder $<.obj | tsort`
+       ${RANLIB} $@.pic
+       @rm -f $@
+       $(LD) -x -Bshareable -Bforcearchive \
+         -o $@ $@.pic
diff --git a/src/makefiles/Makefile.aix b/src/makefiles/Makefile.aix
new file mode 100644 (file)
index 0000000..acd10c2
--- /dev/null
@@ -0,0 +1,21 @@
+# MAKE_EXPORTS is required for svr4 loaders that want a file of
+# symbol names to tell them what to export/import.
+MAKE_EXPORTS= true
+
+EXPSUFF= .exp
+
+POSTGRES_EXP= $(SRCDIR)/backend/postgres$(EXPSUFF)
+
+MKLDEXPORT=$(SRCDIR)/backend/port/aix/mkldexport.sh
+
+%$(EXPSUFF):  %.o
+       $(MKLDEXPORT) $< `pwd` > $@
+
+$(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:$(POSTGRES_EXP) -bE:$*$(EXPSUFF) \
+         $*.o @MATH_LIB@ -lc 2>/dev/null
diff --git a/src/makefiles/Makefile.alpha b/src/makefiles/Makefile.alpha
new file mode 100644 (file)
index 0000000..a9e8e94
--- /dev/null
@@ -0,0 +1,2 @@
+%.so:  %.o
+       $(LD) -shared -expect_unresolved '*' -o $@ $<
diff --git a/src/makefiles/Makefile.dgux b/src/makefiles/Makefile.dgux
new file mode 100644 (file)
index 0000000..21a43c0
--- /dev/null
@@ -0,0 +1,2 @@
+%.so: %.o
+       $(CC) -shared -o $@ $<
diff --git a/src/makefiles/Makefile.hpux b/src/makefiles/Makefile.hpux
new file mode 100644 (file)
index 0000000..9b530f7
--- /dev/null
@@ -0,0 +1,23 @@
+
+#ifdef ENFORCE_ALIGNMENT
+#   CFLAGS_BE= -DNOFIXADE
+#else
+#   HPUX_VERS:= $(shell uname -r)
+#   HPUX_MAJOR= ${HPUX_VERS:R:E}
+#   HPUX_MINOR= ${HPUX_VERS:E}
+#   ifeq ($(HPUX_MAJOR), 08)
+#      CFLAGS_BE+= +u -DHP_S500_ALIGN
+#      LDFLAGS_BE+= +u
+#   else
+#   ifeq ($(HPUX_MAJOR), 09)
+#      ifeq ($(CC), cc)
+#         CFLAGS_BE+= +u4 
+#         LDFLAGS_BE+= +u4
+#      endif
+#   endif
+#   endif
+#endif
+
+%.sl: %.o
+       $(LD) -b -o $@ $<
+
diff --git a/src/makefiles/Makefile.i386_solaris b/src/makefiles/Makefile.i386_solaris
new file mode 100644 (file)
index 0000000..b67d7ed
--- /dev/null
@@ -0,0 +1,2 @@
+%.so: %.o
+       $(LD) -G -Bdynamic -o $@ $<
diff --git a/src/makefiles/Makefile.irix5 b/src/makefiles/Makefile.irix5
new file mode 100644 (file)
index 0000000..e0f705d
--- /dev/null
@@ -0,0 +1,7 @@
+
+# RANLIB is not used on IRIX 5
+RANLIB= touch
+
+%.so: %.o
+       $(LD) -G -Bdynamic -o $@ $< $(LDFLAGS)
+
diff --git a/src/makefiles/Makefile.linux b/src/makefiles/Makefile.linux
new file mode 100644 (file)
index 0000000..21df0c8
--- /dev/null
@@ -0,0 +1,8 @@
+ifdef LINUX_ELF
+LDFLAGS+= -rdynamic
+endif
+MK_NO_LORDER= true
+
+%.so: %.o
+       $(CC) -shared -o $@ $<
+
diff --git a/src/makefiles/Makefile.sparc_solaris b/src/makefiles/Makefile.sparc_solaris
new file mode 100644 (file)
index 0000000..b67d7ed
--- /dev/null
@@ -0,0 +1,2 @@
+%.so: %.o
+       $(LD) -G -Bdynamic -o $@ $<
diff --git a/src/makefiles/Makefile.sunos4 b/src/makefiles/Makefile.sunos4
new file mode 100644 (file)
index 0000000..3bcdf08
--- /dev/null
@@ -0,0 +1,2 @@
+%.so: %.o
+       $(LD) -dc -dp -Bdynamic -o $@ $<
diff --git a/src/makefiles/Makefile.svr4 b/src/makefiles/Makefile.svr4
new file mode 100644 (file)
index 0000000..9c9e5b3
--- /dev/null
@@ -0,0 +1,9 @@
+# MAKE_EXPORTS is required for svr4 loaders that want a file of
+# symbol names to tell them what to export/import.
+MAKE_EXPORTS= true
+
+LDFLAGS+= /usr/ucblib/libucb.a -LD-Blargedynsym
+
+%.so: %.o
+       $(LD) -G -Bdynamic -o $@ $<
+
diff --git a/src/makefiles/Makefile.ultrix4 b/src/makefiles/Makefile.ultrix4
new file mode 100644 (file)
index 0000000..cf46e90
--- /dev/null
@@ -0,0 +1,2 @@
+# install creates intermediate directories
+NO_BEFOREINSTL= true
diff --git a/src/makefiles/Makefile.univel b/src/makefiles/Makefile.univel
new file mode 100644 (file)
index 0000000..3bfc5c0
--- /dev/null
@@ -0,0 +1,12 @@
+#
+#      The univel port is almost guaranteed NOT to work yet.
+#
+# MAKE_EXPORTS is required for svr4 loaders that want a file of
+# symbol names to tell them what to export/import.
+#MAKE_EXPORTS= true
+
+%.so: %.o
+       $(LD) -G -Bdynamic -o $@ $<
+
+INSTALL= /usr/ucb/install
+