Problem: --version-script not used on OpenBSD

Solution: switch to libtool symbol visibility support, which leads to
more portable constructs in the autotools glue.  As noted in the libtool
documentation "This option has no effect on some platforms."

After this commit, global symbols intended to be kept private will
disappear on platforms that were previously not handled
using -Wl,--version-script.
This commit is contained in:
Jérémie Courrèges-Anglas 2018-12-07 16:29:12 +01:00 committed by Jeremie Courreges-Anglas
parent f615b8fdfc
commit 70b48a9c0c
2 changed files with 5 additions and 11 deletions

View File

@ -294,20 +294,17 @@ else
if ON_LINUX
src_libzmq_la_LDFLAGS = \
-version-info @LTVER@ \
@LIBZMQ_EXTRA_LDFLAGS@ \
-Wl,--version-script=$(srcdir)/src/libzmq.vers
@LIBZMQ_EXTRA_LDFLAGS@
else
if ON_GNU
src_libzmq_la_LDFLAGS = \
-version-info @LTVER@ \
@LIBZMQ_EXTRA_LDFLAGS@ \
-Wl,--version-script=$(srcdir)/src/libzmq.vers
@LIBZMQ_EXTRA_LDFLAGS@
else
if ON_DEBIAN_KFREEBSD
src_libzmq_la_LDFLAGS = \
-version-info @LTVER@ \
@LIBZMQ_EXTRA_LDFLAGS@ \
-Wl,--version-script=$(srcdir)/src/libzmq.vers
@LIBZMQ_EXTRA_LDFLAGS@
else
src_libzmq_la_LDFLAGS = \
-version-info @LTVER@ \
@ -320,6 +317,8 @@ endif
endif
endif
src_libzmq_la_LDFLAGS += -export-symbols-regex '^zmq_.*'
src_libzmq_la_CPPFLAGS = $(CODE_COVERAGE_CPPFLAGS) $(LIBUNWIND_CFLAGS)
src_libzmq_la_CFLAGS = $(CODE_COVERAGE_CFLAGS) $(LIBUNWIND_CFLAGS)
src_libzmq_la_CXXFLAGS = @LIBZMQ_EXTRA_CXXFLAGS@ $(CODE_COVERAGE_CXXFLAGS) \
@ -1047,7 +1046,6 @@ EXTRA_DIST = \
version.sh \
src/libzmq.pc.cmake.in \
ci_build.sh \
src/libzmq.vers \
src/version.rc.in \
tests/CMakeLists.txt \
unittests/CMakeLists.txt \

View File

@ -1,4 +0,0 @@
{
global: zmq_*;
local: *;
};