dnl Gone configure script. Compile with autoconf. dnl $MCom: gone/configure.in,v 1.3 2010/08/01 05:53:03 marcus Exp $ undefine([Irix]) undefine([FreeBSD]) undefine([Linux]) undefine([Ultrix]) undefine([OSF1]) AC_INIT(gone.c) AC_CONFIG_HEADER(config.h) AC_ARG_PROGRAM PRODUCT=gone VERSION=1.3.6 AC_DEFINE_UNQUOTED(PRODUCT, "$PRODUCT") AC_DEFINE_UNQUOTED(VERSION, "$VERSION") AC_SUBST(PRODUCT) AC_SUBST(VERSION) AC_PROG_GCC_TRADITIONAL AC_PROG_INSTALL AC_CHECK_HEADERS(crypt.h sys/stat.h sys/param.h sys/stat.h errno.h \ termios.h sys/time.h time.h sys/termio.h string.h sys/ioctl.h sys/consio.h) LIBS= AC_CHECK_LIB(crypt, crypt, [LIBS="-lcrypt"; break]) if test "$with_setuid" = ""; then if test -x /usr/ucb/id ; then UID=`/usr/xpg4/bin/id -u -r` else UID=`id -u -r` fi if test "$UID" = 0; then echo " " echo "Gone gives you the option of installing itself setuid to root." echo "If you choose to install gone in this manner, you will be able" echo "to use your login password as your gone password by giving gone" echo -n "the -p option. Should I install gone setuid (enter 'yes' for setuid)?" read with_setuid fi fi AC_MSG_CHECKING(for OS type) OSTYPE=`uname -s` AC_DEFINE_UNQUOTED(OSTYPE, "$OSTYPE") AC_SUBST(OSTYPE) if test "$OSTYPE" = "OSF1" && test "$SETUID_Q" = "yes"; then AC_DEFINE(OSF1,1) AC_SUBST(OSF1) AC_MSG_RESULT(DEC UNIX) SEC=`rcmgr get SECURITY` AC_SUBST(SEC) AC_MSG_CHECKING(for DU security type) if test "$SEC" = "ENHANCED"; then AC_MSG_RESULT(system using Enhanced Security) AC_CHECK_LIB(security, getespwent, [LIBS="-lsecurity $LIBS"; break]) AC_CHECK_LIB(db, set_auth_parameters, [LIBS="-ldb $LIBS"; break]) AC_SUBST(LIBS) AC_DEFINE(EN_SEC,1) AC_SUBST(EN_SEC) else AC_MSG_RESULT(system using Base Security) fi elif test "$OSTYPE" = "ULTRIX"; then AC_DEFINE(ULTRIX,1) AC_SUBST(ULTRIX) AC_MSG_RESULT(ULTRIX) elif test "$OSTYPE" = "IRIX"; then AC_DEFINE(IRIX,1) AC_SUBST(IRIX) AC_MSG_RESULT(IRIX) else AC_MSG_RESULT("$OSTYPE") fi if test "$with_setuid" = "yes"; then AC_CHECK_HEADERS(sys/types.h pwd.h) AC_DEFINE(SETUID,1) AC_SUBST(SETUID) INSTALL_PROGRAM="$INSTALL -o root -m 4755" AC_SUBST(INSTALL_PROGRAM) fi AC_OUTPUT(Makefile)