1 --- freeciv-2.0.7/configure.ac.orig 2005-10-13 09:45:45.000000000 +0200
2 +++ freeciv-2.0.7/configure.ac 2005-12-26 16:30:36.000000000 +0100
4 dnl Checks for additional server libraries:
5 if test x$server = xtrue; then
6 dnl Some systems (e.g., BeOS) need this lib
7 - AC_CHECK_LIB(bind, gethostbyaddr, SERVER_LIBS="-lbind $SERVER_LIBS")
8 + AC_CHECK_FUNC(gethostbyaddr,,[AC_CHECK_LIB(bind, gethostbyaddr, SERVER_LIBS="-lbind $SERVER_LIBS")])
10 dnl Readline library and header files.
13 dnl If the AC_CHECK_FUNCS check finds the function, we don't look any
14 dnl further. This is rumoured to prevent choosing the wrong libs on IRIX.
15 if test $ac_cv_func_gethostbyname = no; then
16 - AC_CHECK_LIB(nsl, gethostbyname, LIBS="-lnsl $LIBS")
17 + AC_SEARCH_LIBS(gethostbyname, nsl)
19 if test $ac_cv_func_connect = no; then
20 - AC_CHECK_LIB(socket, connect, LIBS="-lsocket $LIBS")
21 + AC_SEARCH_LIBS(connect, socket)
23 if test $ac_cv_func_bind = no; then
24 - AC_CHECK_LIB(bind, gethostbyaddr, LIBS="-lbind $LIBS")
25 + AC_SEARCH_LIBS(gethostbyaddr, bind)
28 dnl The use of both AC_FUNC_VSNPRINTF and AC_CHECK_FUNCS(vsnprintf) is