diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2018-09-10 22:22:12 -0400 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2018-09-10 22:22:12 -0400 |
commit | e3aafe200125975022653eb3197bcf03f7744391 (patch) | |
tree | d323f0fc824ce873b8996a1a82c964c2afe6fea9 | |
parent | 6395ac14d99e4a5d9ee1b83dcc382a368e50240c (diff) | |
download | postgresql-e3aafe200125975022653eb3197bcf03f7744391.tar.gz postgresql-e3aafe200125975022653eb3197bcf03f7744391.zip |
Use -Bsymbolic for shared libraries on HP-UX and Solaris.
These platforms are also subject to the mis-linking problem addressed
in commit e3d77ea6b. It's not clear whether we could solve it with
a solution equivalent to GNU ld's version scripts, but -Bsymbolic
appears to fix it, so let's use that.
Like the previous commit, back-patch as far as v10.
Discussion: https://postgr.es/m/153626613985.23143.4743626885618266803@wrigleys.postgresql.org
-rw-r--r-- | src/Makefile.shlib | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Makefile.shlib b/src/Makefile.shlib index 9cfe49749eb..63d5d9e8ee4 100644 --- a/src/Makefile.shlib +++ b/src/Makefile.shlib @@ -198,12 +198,12 @@ ifeq ($(PORTNAME), hpux) shlib = lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION) endif ifeq ($(with_gnu_ld), yes) - LINK.shared = $(CC) -shared + LINK.shared = $(CC) -shared -Wl,-Bsymbolic ifdef soname LINK.shared += -Wl,-h -Wl,$(soname) endif else - LINK.shared = $(LD) -b + LINK.shared = $(LD) -b -Bsymbolic ifdef soname LINK.shared += +h $(soname) endif @@ -240,9 +240,9 @@ endif ifeq ($(PORTNAME), solaris) ifeq ($(GCC), yes) - LINK.shared = $(COMPILER) -shared + LINK.shared = $(COMPILER) -shared -Wl,-Bsymbolic else - LINK.shared = $(COMPILER) -G + LINK.shared = $(COMPILER) -G -Bsymbolic endif ifdef soname ifeq ($(with_gnu_ld), yes) |