Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 00ab7b5

Browse files
committed
Fix -Bsymbolic for FreeBSD and OpenBSD. NetBSD already had all these fixes.
1 parent 8213e63 commit 00ab7b5

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

src/Makefile.shlib

+7-5
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
# Copyright (c) 1998, Regents of the University of California
77
#
88
# IDENTIFICATION
9-
# $Header: /cvsroot/pgsql/src/Makefile.shlib,v 1.41 2001/02/10 16:51:39 petere Exp $
9+
# $Header: /cvsroot/pgsql/src/Makefile.shlib,v 1.42 2001/02/10 17:17:39 momjian Exp $
1010
#
1111
#-------------------------------------------------------------------------
1212

@@ -112,7 +112,8 @@ endif
112112
ifeq ($(PORTNAME), openbsd)
113113
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
114114
ifdef ELF_SYSTEM
115-
LINK.shared = $(LD) -x -Bshareable -soname $(soname)
115+
LINK.shared = $(COMPILER) -shared -Wl,-x,-soname,$(soname)
116+
SHLIB_LINK += -lc
116117
else
117118
LINK.shared = $(LD) -x -Bshareable -Bforcearchive
118119
endif
@@ -121,7 +122,7 @@ endif
121122
ifeq ($(PORTNAME), bsdi)
122123
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
123124
ifeq ($(DLSUFFIX), .so)
124-
LINK.shared = $(COMPILER) -shared -Wl,-soname,$(soname)
125+
LINK.shared = $(COMPILER) -shared -Wl,-x,-soname,$(soname)
125126
SHLIB_LINK += -lc
126127
endif
127128
ifeq ($(DLSUFFIX), .o)
@@ -132,7 +133,8 @@ endif
132133
ifeq ($(PORTNAME), freebsd)
133134
ifdef ELF_SYSTEM
134135
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION)
135-
LINK.shared = $(LD) -x -shared -soname $(soname)
136+
LINK.shared = $(COMPILER) -shared -Wl,-x,-soname,$(soname)
137+
SHLIB_LINK += -lc
136138
else
137139
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
138140
LINK.shared = $(LD) -x -Bshareable -Bforcearchive
@@ -142,7 +144,7 @@ endif
142144
ifeq ($(PORTNAME), netbsd)
143145
shlib := lib$(NAME)$(DLSUFFIX).$(SO_MAJOR_VERSION).$(SO_MINOR_VERSION)
144146
ifdef ELF_SYSTEM
145-
LINK.shared = $(COMPILER) -shared -Wl,-soname,$(soname)
147+
LINK.shared = $(COMPILER) -shared -Wl,-x,-soname,$(soname)
146148
else
147149
LINK.shared = $(LD) -x -Bshareable -Bforcearchive
148150
endif

src/makefiles/Makefile.freebsd

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ AROPT = cr
33
ifdef ELF_SYSTEM
44
export_dynamic = -export-dynamic
55
rpath = -R$(libdir)
6-
shlib_symbolic = -Bsymbolic
6+
shlib_symbolic = -Wl,-Bsymbolic
77
endif
88

99
DLSUFFIX = .so

src/makefiles/Makefile.openbsd

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ AROPT = cr
33
ifdef ELF_SYSTEM
44
export_dynamic = -Wl,-E
55
rpath = -R$(libdir)
6-
shlib_symbolic = -Bsymbolic
6+
shlib_symbolic = -Wl,-Bsymbolic
77
endif
88

99
DLSUFFIX = .so

0 commit comments

Comments
 (0)