diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1996-02-01 23:57:15 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1996-02-01 23:57:15 +0000 |
commit | 8b6236f9b9d7bca8f9cf84dc67ab4393e6cc4469 (patch) | |
tree | fa45bc5c0f5341712782e866462888b7ab27192c /gnu/usr.bin/cvs/configure.in | |
parent | 39bff74eb9d99c77aee707a66adbace2dcd1800d (diff) |
$(KRB4) -> \$KRB4 so our /bin/sh won't spit out an error message while
configuring.
Diffstat (limited to 'gnu/usr.bin/cvs/configure.in')
-rw-r--r-- | gnu/usr.bin/cvs/configure.in | 100 |
1 files changed, 38 insertions, 62 deletions
diff --git a/gnu/usr.bin/cvs/configure.in b/gnu/usr.bin/cvs/configure.in index 5c43c46bfd0..32eb799273a 100644 --- a/gnu/usr.bin/cvs/configure.in +++ b/gnu/usr.bin/cvs/configure.in @@ -1,11 +1,11 @@ dnl configure.in for cvs +dnl "$CVSid$" AC_INIT(src/cvs.h) -AC_PREREQ(2.1)dnl Required Autoconf version. +AC_PREREQ(2.4)dnl Required Autoconf version. AC_CONFIG_HEADER(config.h src/options.h) -AC_DEFINE(CVS_SUPPORT) - AC_PROG_CC + AC_AIX AC_MINIX AC_ISC_POSIX @@ -13,6 +13,10 @@ if test "$ISC" = yes; then CFLAGS="$CFLAGS -D_SYSV3" fi +AC_PREFIX_PROGRAM(cvs) + +AC_C_CROSS + AC_C_CONST AC_C_CHAR_UNSIGNED AC_C_INLINE @@ -32,52 +36,10 @@ if test X"$ac_cv_sys_interpreter" != X"yes" ; then AC_MSG_WARN($ac_msg) fi -AC_PATH_PROGS(gdiff_path, gnudiff diff, diff) -AC_MSG_CHECKING(to see if $gdiff_path supports -a) -if $gdiff_path -a /dev/null /dev/null > /dev/null 2>&1 ; then - AC_MSG_RESULT(yes; appending -a to $gdiff_path) - gdiff_path="$gdiff_path -a" -fi -AC_DEFINE_UNQUOTED(DIFF, "$gdiff_path") - -AC_PATH_PROGS(ggrep_path, ggrep gnugrep grep, grep) -AC_MSG_CHECKING(to see if $ggrep_path supports -s) -[echo foostring | $ggrep_path -s foostring > conftest.out 2>/dev/null] -dnl -dnl FIXME: We use a work-around for SunOS users with /usr/5bin first in their -dnl FIXME: path but we should really iterate through all the possible grep's -dnl FIXME: for one that works the way we want it to. -dnl FIXME: On the other hand, we should handle the failure to find a "working" -dnl FIXME: -s option by doing the old fashioned ">/dev/null"..... -dnl -if test $? -ne 0 ; then - AC_MSG_WARN($ggrep_path does not support -s, used when checking for merge conflicts) -else - AC_MSG_RESULT(yes) - AC_MSG_CHECKING(to see if $ggrep_path -s means to work silently) - if test -s conftest.out ; then - AC_MSG_RESULT(no) - if test "$ggrep_path" != /usr/bin/grep ; then - AC_MSG_CHECKING(to see if /usr/bin/grep has the right -s) - [echo foostring | /usr/bin/grep -s foostring > conftest.out 2>/dev/null] - if test $? -eq 0 -a ! -s foostring ; then - AC_MSG_RESULT(yes; using /usr/bin/grep) - ggrep_path=/usr/bin/grep - else - AC_MSG_RESULT(no) - fi - fi - else - AC_MSG_RESULT(yes) - fi -fi -AC_DEFINE_UNQUOTED(GREP, "$ggrep_path") -rm -f conftest* - AC_HEADER_STDC AC_CHECK_HEADERS(errno.h unistd.h string.h memory.h utime.h fcntl.h ndbm.h \ sys/param.h sys/select.h sys/time.h sys/timeb.h \ - io.h direct.h sys/bsdtypes.h) + io.h direct.h sys/bsdtypes.h sys/resource.h) AC_HEADER_SYS_WAIT AC_HEADER_STAT AC_HEADER_TIME @@ -88,7 +50,7 @@ AC_TYPE_MODE_T AC_TYPE_SIZE_T AC_TYPE_PID_T AC_REPLACE_FUNCS(getwd mkdir rename strdup strstr dup2 strerror valloc waitpid memmove) -AC_CHECK_FUNCS(fchmod fsync ftime mkfifo putenv setvbuf vfork vprintf ftruncate timezone getpagesize fchdir) +AC_CHECK_FUNCS(fchmod fsync ftime mkfifo putenv setvbuf vfork vprintf ftruncate timezone getpagesize fchdir sigaction sigprocmask sigvec sigsetmask sigblock) AC_CHECK_FUNC(re_exec, :, LIBOBJS="$LIBOBJS regex.o") AC_FUNC_UTIME_NULL AC_FUNC_ALLOCA @@ -114,12 +76,13 @@ fi AC_MSG_RESULT($ccvs_cv_sys_working_fnmatch) dnl -dnl set $(KRB4) from --with-krb4=value -- WITH_KRB4 +dnl set $KRB4 from --with-krb4=value -- WITH_KRB4 dnl -define(WITH_KRB4,[ -AC_WITH([krb4], -KRB4=$withval, KRB4=/usr/kerberos +define(WITH_KRB4,[ +AC_ARG_WITH([krb4], + [ --with-krb4=value set default \$KRB4 from value], + [KRB4=$withval], )dnl echo "default place for krb4 is $KRB4" AC_SUBST(KRB4)])dnl @@ -128,21 +91,33 @@ WITH_KRB4 AC_CHECK_SIZEOF(long) AC_CHECK_SIZEOF(int) -AC_REQUIRE([AC_CROSS_CHECK]) krb_h= -AC_COMPILE_CHECK(krb.h,[#include <krb.h>],[int i;], +AC_MSG_CHECKING([for krb.h]) +AC_TRY_LINK([#include <krb.h>],[int i;], [krb_h=yes krb_incdir=], [if test "$cross_compiling" != yes && test -r $KRB4/include/krb.h; then hold_cflags=$CFLAGS CFLAGS="$CFLAGS -I$KRB4/include" - AC_COMPILE_CHECK(krb.h in $KRB4/include, - [#include <krb.h>],[int i;], + AC_TRY_LINK([#include <krb.h>],[int i;], [krb_h=yes krb_incdir=$KRB4/include]) CFLAGS=$hold_cflags fi]) +if test -z "$krb_h"; then + AC_TRY_LINK([#include <krb.h>],[int i;], + [krb_h=yes krb_incdir=], + [if test "$cross_compiling" != yes && test -r $KRB4/include/kerberosIV/krb.h; then + hold_cflags=$CFLAGS + CFLAGS="$CFLAGS -I$KRB4/include/kerberosIV" + AC_TRY_LINK([#include <krb.h>],[int i;], + [krb_h=yes krb_incdir=$KRB4/include/kerberosIV]) + CFLAGS=$hold_cflags + fi]) +fi +AC_MSG_RESULT($krb_h) + if test -n "$krb_h"; then krb_lib= - AC_HAVE_LIBRARY(-lkrb,[krb_lib=yes krb_libdir=], + AC_CHECK_LIB(krb,main,[krb_lib=yes krb_libdir=], [if test "$cross_compiling" != yes && test -r $KRB4/lib/libkrb.a; then krb_lib=yes krb_libdir=$KRB4/lib fi]) @@ -150,7 +125,7 @@ if test -n "$krb_h"; then AC_DEFINE(HAVE_KERBEROS) test -n "${krb_libdir}" && LIBS="${LIBS} -L${krb_libdir}" LIBS="${LIBS} -lkrb" - AC_HAVE_LIBRARY(-ldes,[LIBS="${LIBS} -ldes"]) + AC_CHECK_LIB(des,main,[LIBS="${LIBS} -ldes"]) if test -n "$krb_incdir"; then includeopt="${includeopt} -I$krb_incdir" AC_SUBST(includeopt) @@ -165,19 +140,19 @@ AC_CHECK_FUNCS(krb_get_err_text) # it. unset ac_cv_func_connect AC_CHECK_FUNC(connect, :, -[case $LIBS in +[case "$LIBS" in *-lnsl*) ;; *) AC_CHECK_LIB(nsl_s, main) ;; esac -case $LIBS in +case "$LIBS" in *-lnsl*) ;; *) AC_CHECK_LIB(nsl, main) ;; esac -case $LIBS in +case "$LIBS" in *-lsocket*) ;; *) AC_CHECK_LIB(socket, connect) ;; esac -case $LIBS in +case "$LIBS" in *-linet*) ;; *) AC_CHECK_LIB(inet, connect) ;; esac @@ -201,4 +176,5 @@ test -f src/options.h && ( AC_OUTPUT(Makefile lib/Makefile src/Makefile doc/Makefile \ man/Makefile contrib/Makefile contrib/pcl-cvs/Makefile \ - examples/Makefile windows-NT/Makefile stamp-h) + examples/Makefile windows-NT/Makefile os2/Makefile \ + macintosh/Makefile stamp-h) |