Skip to content

Commit

Permalink
Merge pull request #3263 from pieterlexis/3.4-musl-fixes
Browse files Browse the repository at this point in the history
3.4 musl fixes
  • Loading branch information
pieterlexis committed Jan 20, 2016
2 parents 19c52d4 + a2e5c28 commit 5b06f55
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 22 deletions.
1 change: 1 addition & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ compiler:
- clang
before_script:
- git describe --always --dirty=+
- sudo sysctl net.ipv6.conf.lo.disable_ipv6=0
- sudo /sbin/ip addr add 10.0.3.0/24 dev lo
- sudo /sbin/ip addr add 1.2.3.4/32 dev lo
- sudo rm /etc/apt/sources.list.d/travis_ci_zeromq3-source.list
Expand Down
28 changes: 6 additions & 22 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -41,13 +41,9 @@ AS_IF([test "x$enable_hardening" != "xno"], [
AC_LD_RELRO
])

AC_CHECK_FUNC([socket], [], [
AC_CHECK_LIB([socket], [socket], [LIBS="-lsocket $LIBS"])
])

AC_CHECK_FUNC([gethostent], [], [
AC_CHECK_LIB([nsl], [gethostent], [LIBS="-lnsl $LIBS"])
])
AC_SEARCH_LIBS([socket], [socket])
AC_SEARCH_LIBS([gethostent], [nsl])
AC_SEARCH_LIBS([inet_aton], [resolv])

m4_ifndef([LT_INIT],[
AC_PROG_LIBTOOL([disable-static])
Expand Down Expand Up @@ -164,21 +160,20 @@ AM_CONDITIONAL([OS_MACOSX], false)
case "$host_os" in
solaris2.10)
AC_DEFINE(HAVE_IPV6,1,[If the host operating system understands IPv6])
LIBS="-lposix4 -lresolv -lnsl -lsocket -lpthread -lrt $LIBS"
LIBS="-lposix4 -lpthread -lrt $LIBS"
CXXFLAGS="-D_REENTRANT $CXXFLAGS"
;;

solaris2.8 | solaris2.9 )
AC_DEFINE(NEED_POSIX_TYPEDEF,,[If POSIX typedefs need to be defined])
AC_DEFINE(NEED_INET_NTOP_PROTO,,[If your OS is so broken that it needs an additional prototype])
AC_DEFINE(HAVE_IPV6,1,[If the host operating system understands IPv6])
LIBS="-lposix4 -lresolv -lnsl -lsocket -lpthread $LIBS"
LIBS="-lposix4 -lpthread $LIBS"
CXXFLAGS="-D_REENTRANT $CXXFLAGS"
;;
solaris2.6 | solaris2.7)
AC_DEFINE(NEED_POSIX_TYPEDEF,,[If POSIX typedefs need to be defined])
AC_DEFINE(NEED_INET_NTOP_PROTO,,[If your OS is so broken that it needs an additional prototype])
LIBS="-lposix4 -lresolv -lnsl -lsocket -lpthread $LIBS"
LIBS="-lposix4 -lpthread $LIBS"
CXXFLAGS="-D_REENTRANT $CXXFLAGS"
;;
linux*)
Expand Down Expand Up @@ -332,17 +327,6 @@ for a in $modules; do

if test ${a} = "gpgsql"; then
LIBS="$LIBS $LIBCRYPT"

case "$host_os" in
freebsd*)
;;
darwin*)
modulelibs="$modulelibs -lresolv"
;;
*)
modulelibs="$modulelibs -lresolv -lnsl"
;;
esac
fi
done

Expand Down

0 comments on commit 5b06f55

Please sign in to comment.