Fix autoconfiguration of libraries
configure checked for library functions with LIBS instead of
LIBS_server, which could break detection of getaddrinfo() on systems
where LIB_SOCKET isn't empty.
GNUmakefile put @PTHREAD_LIBS@ only in LDLIBS, which breaks linking of
server and possibly client on systems where it is not empty.
Broken in commit 8b778634
.
This commit is contained in:
parent
a977bd08f6
commit
70a9a44bbc
2 changed files with 9 additions and 11 deletions
13
configure.ac
13
configure.ac
|
@ -69,14 +69,10 @@ MY_WINDOWS_API
|
|||
|
||||
### Checks for libraries
|
||||
ACX_PTHREAD
|
||||
save_LIBS="$LIBS"
|
||||
LIBS_util="$LIBS"
|
||||
LIBS="$LIBS_SOCKETS $LIBS"
|
||||
LIB_SOCKET_NSL
|
||||
LIBS_server="$LIBS"
|
||||
LIBS_client="$LIBS"
|
||||
LIBS="$save_LIBS"
|
||||
AC_SUBST(LIBS_server)
|
||||
AC_SUBST(LIBS_client)
|
||||
|
||||
|
||||
### Checks for header files
|
||||
|
@ -134,15 +130,16 @@ POSIX) AC_DEFINE([EMPTH_POSIX], 1, [Define to use POSIX threads]) ;;
|
|||
Windows) AC_DEFINE([EMPTH_W32], 1, [Define to use Windows threads]) ;;
|
||||
esac
|
||||
|
||||
save_LIBS="$LIBS"
|
||||
LIBS="$LIBS_client"
|
||||
MY_WITH_TERMINFO
|
||||
LIBS_client="$LIBS"
|
||||
LIBS="$save_LIBS"
|
||||
|
||||
|
||||
### Output
|
||||
|
||||
LIBS="$LIBS_util"
|
||||
AC_SUBST(LIBS_client)
|
||||
AC_SUBST(LIBS_server)
|
||||
|
||||
AC_CONFIG_FILES([GNUmakefile])
|
||||
AC_CONFIG_COMMANDS([stamp-h],
|
||||
[case $revctrl in
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue