diff options
author | Haru <haru@dotalux.com> | 2014-10-24 00:40:42 +0200 |
---|---|---|
committer | Haru <haru@dotalux.com> | 2014-10-24 00:51:37 +0200 |
commit | bf2d0b4295b5197ce6d303e8124c470613df94bf (patch) | |
tree | 1f289566edf4c2218da14f47dc335496b0ff583b /configure.in | |
parent | 32d658cc23e4f935a388876a8525ac0e7159154a (diff) | |
download | hercules-bf2d0b4295b5197ce6d303e8124c470613df94bf.tar.gz hercules-bf2d0b4295b5197ce6d303e8124c470613df94bf.tar.bz2 hercules-bf2d0b4295b5197ce6d303e8124c470613df94bf.tar.xz hercules-bf2d0b4295b5197ce6d303e8124c470613df94bf.zip |
Fixed an issue with $LIBS in the configure script
- It is now possible to pass custom LIBS values to ./configure by
specifying them on the command line
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'configure.in')
-rw-r--r-- | configure.in | 92 |
1 files changed, 46 insertions, 46 deletions
diff --git a/configure.in b/configure.in index ef0dea87c..cd1dbea1d 100644 --- a/configure.in +++ b/configure.in @@ -1118,6 +1118,52 @@ case $enable_renewal in esac # +# Host specific stuff +# +AC_MSG_CHECKING([host OS]) +host_os="`uname`" +AC_MSG_RESULT([$host_os]) +fd_setsize="" +DLLEXT=".so" +case $host_os in +Solaris* ) + LIBS="$LIBS -lsocket -lnsl -ldl" + ;; +Linux* ) + LIBS="$LIBS -ldl" + ;; +FreeBSD*) + CPPFLAGS="$CPPFLAGS -D__FREEBSD__" + ;; +NetBSD*) + CPPFLAGS="$CPPFLAGS -D__NETBSD__" + ;; +CYGWIN*) + CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=4096 -DCYGWIN" + fd_setsize="done" + DLLEXT=".dll" + ;; +Darwin*) + DLLEXT=".dylib" + ;; +esac +AC_SUBST([DLLEXT]) + +AC_MSG_CHECKING([for MinGW]) +if test -n "`$CC --version 2>/dev/null | grep -i mingw`" ; then + AC_MSG_RESULT([yes]) + CPPFLAGS="$CPPFLAGS -DMINGW" + if test -z "$fd_setsize" ; then + CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=4096" + fi + LIBS="$LIBS -lws2_32" +else + AC_MSG_RESULT([no]) +fi + + + +# # zlib library (required) # if test -n "${ZLIB_HOME}" ; then @@ -1351,51 +1397,5 @@ AC_CHECK_PROG([HAVE_DOXYGEN],[doxygen],[yes],[no]) AC_CHECK_PROG([HAVE_PERL],[perl],[yes],[no]) -# -# Host specific stuff -# -AC_MSG_CHECKING([host OS]) -host_os="`uname`" -AC_MSG_RESULT([$host_os]) -fd_setsize="" -DLLEXT=".so" -case $host_os in -Solaris* ) - LIBS="$LIBS -lsocket -lnsl -ldl" - ;; -Linux* ) - LIBS="$LIBS -ldl" - ;; -FreeBSD*) - CPPFLAGS="$CPPFLAGS -D__FREEBSD__" - ;; -NetBSD*) - CPPFLAGS="$CPPFLAGS -D__NETBSD__" - ;; -CYGWIN*) - CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=4096 -DCYGWIN" - fd_setsize="done" - DLLEXT=".dll" - ;; -Darwin*) - DLLEXT=".dylib" - ;; -esac -AC_SUBST([DLLEXT]) - -AC_MSG_CHECKING([for MinGW]) -if test -n "`$CC --version 2>/dev/null | grep -i mingw`" ; then - AC_MSG_RESULT([yes]) - CPPFLAGS="$CPPFLAGS -DMINGW" - if test -z "$fd_setsize" ; then - CPPFLAGS="$CPPFLAGS -DFD_SETSIZE=4096" - fi - LIBS="$LIBS -lws2_32" -else - AC_MSG_RESULT([no]) -fi - - - ############################################################################### AC_OUTPUT |