From 0865f587ea9bdb0c14cc71f4cf3a27ae8eb0aa19 Mon Sep 17 00:00:00 2001 From: "Marc G. Fournier" Date: Sun, 5 Jan 1997 23:52:21 +0000 Subject: [PATCH] Shared library fixes for BSD44_Derived port Submitted by: "Martin J. Laubach" NOTE: The following patch I was uncertain of, but applied it...will end up testing the compile on my machine later tonight anyway, but if anyone knows why this *shouldn't* have been done, please change it. (CC -> LD) *************** *** 61,68 **** ../backend/lib/dllist.o: $(MAKE) -C ../backend/lib dllist.o ! libpq.so.1: $(OBJS) ! $(CC) $(LDFLAGS) -shared $(OBJS) -o libpq.so.1 c.h: ../include/c.h rm -f c.h --- 66,73 ---- ../backend/lib/dllist.o: $(MAKE) -C ../backend/lib dllist.o ! $(shlib): $(OBJS) ! $(LD) $(LDFLAGS) -shared $(OBJS) -o $(shlib) c.h: ../include/c.h rm -f c.h --- src/interfaces/libpq/Makefile | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/src/interfaces/libpq/Makefile b/src/interfaces/libpq/Makefile index f831192131..414c0f929f 100644 --- a/src/interfaces/libpq/Makefile +++ b/src/interfaces/libpq/Makefile @@ -7,7 +7,7 @@ # # # IDENTIFICATION -# $Header: /cvsroot/pgsql/src/interfaces/libpq/Makefile,v 1.22 1996/12/10 07:05:09 bryanh Exp $ +# $Header: /cvsroot/pgsql/src/interfaces/libpq/Makefile,v 1.23 1997/01/05 23:52:21 scrappy Exp $ # #------------------------------------------------------------------------- @@ -38,6 +38,11 @@ ifdef LINUX_ELF ifeq ($(PORTNAME), linux) shlib := libpq.so.1 endif +ifeq ($(PORTNAME), BSD44_derived) +shlib := libpq.so.1.0 +CFLAGS+= -fpic -DPIC +LDFLAGS=-Bshareable -Bforcearchive +endif endif all: libpq.a $(shlib) c.h @@ -62,7 +67,7 @@ fe-lobj.o: ../backend/fmgr.h $(MAKE) -C ../backend/lib dllist.o libpq.so.1: $(OBJS) - $(CC) $(LDFLAGS) -shared $(OBJS) -o libpq.so.1 + $(LD) $(LDFLAGS) -shared $(OBJS) -o $(shlib) c.h: ../include/c.h rm -f c.h @@ -136,7 +141,7 @@ install-libpq: libpq.a $(INSTALL) $(INSTL_LIB_OPTS) libpq.a $(DESTDIR)$(LIBDIR)/libpq.a install-shlib: libpq.so.1 - $(INSTALL) $(INSTL_LIB_OPTS) libpq.so.1 $(DESTDIR)$(LIBDIR)/libpq.so.1 + $(INSTALL) $(INSTL_LIB_OPTS) $(shlib) $(DESTDIR)$(LIBDIR)/$(shlib) depend dep: $(CC) -MM $(INCLUDE_OPT) *.c >depend -- 2.40.0