Try fixing unixODBC deadlock with -Bsymbolic-functions

This flag compels the dynamic library to prefer its own function symbols
to those in the global symbol table. This behavior should let us
directly call SQL* functions from inside other SQL* functions without
fear of interference by the host program.
This commit is contained in:
Evan Miller
2020-08-13 21:52:03 -04:00
parent 4f330ea6be
commit dfd41f2283
2 changed files with 2 additions and 4 deletions

View File

@@ -70,9 +70,7 @@ AC_SUBST(LFLAGS)
CFLAGS="$CFLAGS -Wall -Werror"
AS_CASE([$host],
[*mingw*|*cygwin*], [LDFLAGS="$LDFLAGS -no-undefined"],
[*darwin*], [],
[LDFLAGS="$LDFLAGS -Wl,--no-undefined"])
[*mingw*|*cygwin*], [LDFLAGS="$LDFLAGS -no-undefined"], [])
AS_CASE([$host],
[*mingw*], [LDFLAGS="$LDFLAGS -lWs2_32"], [])
dnl Enable -Wl,--as-needed by default to prevent overlinking