pkgsrc/databases/postgresql74/patches/patch-aa
jlam a1dc1c896f Patch Makefile.shlib so that when creating shared libraries, we don't
only pass only the -L* LDFLAGS to the linker.  This is correct for
pkgsrc since the wrapper scripts take care of correctly passing the
rpath info to the linker, so we don't need to filter those out.  This
allows plpgsql.so to find libintl.so if we are using the pkgsrc version
of it.  Bump the PKGREVISION of postgresql*-lib to 7.3.8nb1 and
7.4.6nb2.

Link the postgres binary with the necessary flags to allow it to
dlopen() modules that use pthreads[*].  This should allow postgres to
open a plperl.so module built on a system with perl+threads.  Bump
the PKGREVISION of postgresql*-server to 7.3.8nb2 and 7.4.6nb2.

[*] Note that this behavior can be tweaked globally by setting
    DLOPEN_REQUIRE_PTHREADS to "yes" or "no" in /etc/mk.conf.
2004-12-18 15:59:55 +00:00

40 lines
1.4 KiB
Text

$NetBSD: patch-aa,v 1.2 2004/12/18 15:59:55 jlam Exp $
--- src/Makefile.shlib.orig 2003-10-19 21:34:33.000000000 -0400
+++ src/Makefile.shlib
@@ -108,7 +108,7 @@ endif
ifeq ($(PORTNAME), freebsd)
ifdef ELF_SYSTEM
- shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION)
+ shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
LINK.shared = $(COMPILER) -shared -Wl,-x,-soname,$(soname)
else
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
@@ -126,7 +126,7 @@ ifeq ($(PORTNAME), netbsd)
endif
ifeq ($(PORTNAME), hpux)
- shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION)
+ shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
LINK.shared = $(LD) +h $(soname) -b +b $(libdir)
ifeq ($(GCC), yes)
SHLIB_LINK += `$(CC) -print-libgcc-file-name`
@@ -134,7 +134,7 @@ ifeq ($(PORTNAME), hpux)
endif
ifeq ($(PORTNAME), irix5)
- shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION)
+ shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
LINK.shared = $(COMPILER) -shared -Wl,-set_version,sgi$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
endif
@@ -207,7 +207,7 @@ ifeq ($(PORTNAME), beos)
SHLIB_LINK += -ltermcap -lstdc++.r4 -lbind -lsocket -L/boot/develop/lib/x86
endif
-SHLIB_LINK := $(filter -L%, $(LDFLAGS)) $(SHLIB_LINK)
+SHLIB_LINK := $(LDFLAGS) $(SHLIB_LINK)
ifeq ($(enable_rpath), yes)
SHLIB_LINK += $(rpath)
endif