diff --git a/Jamfile b/Jamfile index 88526e8aa..3fdbfb575 100755 --- a/Jamfile +++ b/Jamfile @@ -543,8 +543,14 @@ lib torrent # hide non-external symbols darwin:-fvisibility=hidden + darwin:-fvisibility-inlines-hidden + darwin:-W1,-Bsymbolic gcc:-fvisibility=hidden + gcc:-fvisibility-inlines-hidden + gcc:-W1,-Bsymbolic llvm:-fvisibility=hidden + llvm:-fvisibility-inlines-hidden + llvm:-W1,-Bsymbolic $(usage-requirements) diff --git a/configure.ac b/configure.ac index 1cc9f3588..0901f532b 100644 --- a/configure.ac +++ b/configure.ac @@ -97,7 +97,8 @@ AS_ECHO "Checking for posix thread support:" AX_PTHREAD() LIBS="$PTHREAD_LIBS $LIBS" -CFLAGS="$PTHREAD_CFLAGS $CFLAGS" +CFLAGS="$PTHREAD_CFLAGS $CFLAGS -fvisibility=hidden" +CXXFLAGS="$CXXFLAGS -fvisibility=hidden -fvisibility-inlines-hidden" CC="$PTHREAD_CC" AS_ECHO