From 59e32a18c9fb50058e588693907ad7b02a7b9daf Mon Sep 17 00:00:00 2001 From: Timo Sirainen Date: Sat, 19 Jan 2002 23:36:11 +0000 Subject: [PATCH] Don't use -lnsl or -lsocket if it's not needed. git-svn-id: http://svn.irssi.org/repos/irssi/trunk@2323 dbcabf3a-b0e7-0310-adc4-f8d773084564 --- configure.in | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/configure.in b/configure.in index 44f28e2d..1282e2fd 100644 --- a/configure.in +++ b/configure.in @@ -213,9 +213,6 @@ case "$host_os" in hpux*) CFLAGS="$CFLAGS -D_XOPEN_SOURCE_EXTENDED" ;; - irix*) - skip_extralibs=true - ;; *) ;; esac @@ -223,15 +220,17 @@ esac AC_CHECK_FUNCS(mkfifo fcntl) -if test "x$skip_extralibs" != "xtrue"; then +AC_CHECK_FUNC(socket, [], [ AC_CHECK_LIB(socket, socket, [ LIBS="$LIBS -lsocket" ]) +]) +AC_CHECK_FUNC(inet_addr, [], [ AC_CHECK_LIB(nsl, inet_addr, [ LIBS="$LIBS -lnsl" ], -lsocket) -fi +]) dnl * gcc specific options if test "x$ac_cv_prog_gcc" = "xyes"; then