Commit cc618f26 authored by Bruce Momjian's avatar Bruce Momjian

Add search for libgetopt.a in hopes of finding getopt_long().

parent b9104e3a
...@@ -6045,6 +6045,65 @@ _ACEOF ...@@ -6045,6 +6045,65 @@ _ACEOF
fi fi
echo "$as_me:$LINENO: checking for main in -lgetopt" >&5
echo $ECHO_N "checking for main in -lgetopt... $ECHO_C" >&6
if test "${ac_cv_lib_getopt_main+set}" = set; then
echo $ECHO_N "(cached) $ECHO_C" >&6
else
ac_check_lib_save_LIBS=$LIBS
LIBS="-lgetopt $LIBS"
cat >conftest.$ac_ext <<_ACEOF
#line $LINENO "configure"
#include "confdefs.h"
#ifdef F77_DUMMY_MAIN
# ifdef __cplusplus
extern "C"
# endif
int F77_DUMMY_MAIN() { return 1; }
#endif
int
main ()
{
main ();
;
return 0;
}
_ACEOF
rm -f conftest.$ac_objext conftest$ac_exeext
if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
(eval $ac_link) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); } &&
{ ac_try='test -s conftest$ac_exeext'
{ (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
(eval $ac_try) 2>&5
ac_status=$?
echo "$as_me:$LINENO: \$? = $ac_status" >&5
(exit $ac_status); }; }; then
ac_cv_lib_getopt_main=yes
else
echo "$as_me: failed program was:" >&5
cat conftest.$ac_ext >&5
ac_cv_lib_getopt_main=no
fi
rm -f conftest.$ac_objext conftest$ac_exeext conftest.$ac_ext
LIBS=$ac_check_lib_save_LIBS
fi
echo "$as_me:$LINENO: result: $ac_cv_lib_getopt_main" >&5
echo "${ECHO_T}$ac_cv_lib_getopt_main" >&6
if test $ac_cv_lib_getopt_main = yes; then
cat >>confdefs.h <<_ACEOF
#define HAVE_LIBGETOPT 1
_ACEOF
LIBS="-lgetopt $LIBS"
fi
# QNX: # QNX:
echo "$as_me:$LINENO: checking for main in -lunix" >&5 echo "$as_me:$LINENO: checking for main in -lunix" >&5
...@@ -11070,7 +11129,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11070,7 +11129,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
GETRUSAGE='getrusage.o' GETRUSAGE='$(top_builddir)/src/backend/port/getrusage.o'
fi fi
done done
...@@ -11149,7 +11208,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11149,7 +11208,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
SRANDOM='srandom.o' SRANDOM='$(top_builddir)/src/backend/port/srandom.o'
fi fi
done done
...@@ -11228,7 +11287,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11228,7 +11287,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
GETHOSTNAME='gethostname.o' GETHOSTNAME='$(top_builddir)/src/backend/port/gethostname.o'
fi fi
done done
...@@ -11307,7 +11366,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11307,7 +11366,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
MISSING_RANDOM='random.o' MISSING_RANDOM='$(top_builddir)/src/backend/port/random.o'
fi fi
done done
...@@ -11386,7 +11445,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11386,7 +11445,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
INET_ATON='inet_aton.o' INET_ATON='$(top_builddir)/src/backend/port/inet_aton.o'
fi fi
done done
...@@ -11623,7 +11682,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11623,7 +11682,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
STRTOL='strtol.o' STRTOL='$(top_builddir)/src/backend/port/strtol.o'
fi fi
done done
...@@ -11702,7 +11761,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11702,7 +11761,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
STRTOUL='strtoul.o' STRTOUL='$(top_builddir)/src/backend/port/strtoul.o'
fi fi
done done
...@@ -11781,7 +11840,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then ...@@ -11781,7 +11840,7 @@ if test `eval echo '${'$as_ac_var'}'` = yes; then
_ACEOF _ACEOF
else else
STRCASECMP='strcasecmp.o' STRCASECMP='$(top_builddir)/src/backend/port/strcasecmp.o'
fi fi
done done
......
dnl Process this file with autoconf to produce a configure script. dnl Process this file with autoconf to produce a configure script.
dnl $Header: /cvsroot/pgsql/configure.in,v 1.188 2002/07/15 21:34:04 momjian Exp $ dnl $Header: /cvsroot/pgsql/configure.in,v 1.189 2002/07/15 22:41:45 momjian Exp $
dnl dnl
dnl Developers, please strive to achieve this order: dnl Developers, please strive to achieve this order:
dnl dnl
...@@ -696,6 +696,7 @@ AC_CHECK_LIB(BSD, main) ...@@ -696,6 +696,7 @@ AC_CHECK_LIB(BSD, main)
AC_CHECK_LIB(gen, main) AC_CHECK_LIB(gen, main)
AC_CHECK_LIB(PW, main) AC_CHECK_LIB(PW, main)
AC_CHECK_LIB(resolv, main) AC_CHECK_LIB(resolv, main)
AC_CHECK_LIB(getopt, main)
# QNX: # QNX:
AC_CHECK_LIB([[unix]], main) AC_CHECK_LIB([[unix]], main)
AC_SEARCH_LIBS(crypt, crypt) AC_SEARCH_LIBS(crypt, crypt)
...@@ -903,25 +904,25 @@ fi ...@@ -903,25 +904,25 @@ fi
AC_SUBST(ISINF) AC_SUBST(ISINF)
AC_CHECK_FUNCS(getrusage, [], GETRUSAGE='getrusage.o') AC_CHECK_FUNCS(getrusage, [], GETRUSAGE='$(top_builddir)/src/backend/port/getrusage.o')
AC_SUBST(GETRUSAGE) AC_SUBST(GETRUSAGE)
AC_CHECK_FUNCS(srandom, [], SRANDOM='srandom.o') AC_CHECK_FUNCS(srandom, [], SRANDOM='$(top_builddir)/src/backend/port/srandom.o')
AC_SUBST(SRANDOM) AC_SUBST(SRANDOM)
AC_CHECK_FUNCS(gethostname, [], GETHOSTNAME='gethostname.o') AC_CHECK_FUNCS(gethostname, [], GETHOSTNAME='$(top_builddir)/src/backend/port/gethostname.o')
AC_SUBST(GETHOSTNAME) AC_SUBST(GETHOSTNAME)
AC_CHECK_FUNCS(random, [], MISSING_RANDOM='random.o') AC_CHECK_FUNCS(random, [], MISSING_RANDOM='$(top_builddir)/src/backend/port/random.o')
AC_SUBST(MISSING_RANDOM) AC_SUBST(MISSING_RANDOM)
AC_CHECK_FUNCS(inet_aton, [], INET_ATON='inet_aton.o') AC_CHECK_FUNCS(inet_aton, [], INET_ATON='$(top_builddir)/src/backend/port/inet_aton.o')
AC_SUBST(INET_ATON) AC_SUBST(INET_ATON)
AC_CHECK_FUNCS(strerror, [], STRERROR='$(top_builddir)/src/backend/port/strerror.o') AC_CHECK_FUNCS(strerror, [], STRERROR='$(top_builddir)/src/backend/port/strerror.o')
AC_SUBST(STRERROR) AC_SUBST(STRERROR)
AC_CHECK_FUNCS(strdup, [], STRDUP='$(top_builddir)/src/utils/strdup.o') AC_CHECK_FUNCS(strdup, [], STRDUP='$(top_builddir)/src/utils/strdup.o')
AC_SUBST(STRDUP) AC_SUBST(STRDUP)
AC_CHECK_FUNCS(strtol, [], STRTOL='strtol.o') AC_CHECK_FUNCS(strtol, [], STRTOL='$(top_builddir)/src/backend/port/strtol.o')
AC_SUBST(STRTOL) AC_SUBST(STRTOL)
AC_CHECK_FUNCS(strtoul, [], STRTOUL='strtoul.o') AC_CHECK_FUNCS(strtoul, [], STRTOUL='$(top_builddir)/src/backend/port/strtoul.o')
AC_SUBST(STRTOUL) AC_SUBST(STRTOUL)
AC_CHECK_FUNCS(strcasecmp, [], STRCASECMP='strcasecmp.o') AC_CHECK_FUNCS(strcasecmp, [], STRCASECMP='$(top_builddir)/src/backend/port/strcasecmp.o')
AC_SUBST(STRCASECMP) AC_SUBST(STRCASECMP)
# On HPUX 9, rint() is not in regular libm.a but in /lib/pa1.1/libm.a; # On HPUX 9, rint() is not in regular libm.a but in /lib/pa1.1/libm.a;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment