# # configure.ac -- input file for configure script # # Note: make sure to run build-configure.sh when any changes are # made to this file or to any of the files in aclocal AC_PREREQ(2.57) AC_INIT(DTN2) AC_CONFIG_SRCDIR([dtn-version.h]) AC_CONFIG_HEADER([config.h]) AC_CONFIG_AUX_DIR(tools) AC_PREFIX_DEFAULT(/usr) # Stick a comment in the generated file so people know what to do. AC_REVISION(-- DO NOT EDIT THIS FILE! See the instructions in configure.ac --) # This is handy to re-run configure but use any options you used before. AC_ARG_WITH(previous-options, [ --with-previous-options read config.status for configure options], [ if test -r ./config.status && args=`sed -n '7s/^# [^ ]* //p' config.status` then set -x exec $0 $args fi ]) # First set srcdir and builddir, calculated above in AC_CONFIG_SRCDIR AC_MSG_CHECKING([location of source directory]) SRCDIR=`(cd $srcdir && pwd)` AC_MSG_RESULT(\"$SRCDIR\") AC_SUBST(SRCDIR) builddir=`pwd` AC_MSG_CHECKING([location of build directory]) AC_MSG_RESULT(\"$builddir\") BUILDDIR=$builddir AC_SUBST(BUILDDIR) dnl ------------------------------------------------------------------------- dnl Checks for programs and libraries dnl ------------------------------------------------------------------------- AC_OASYS_CONFIG_GCC_OPTS AC_OASYS_CONFIG_GCC AC_OASYS_SYSTEM_PROGRAMS AC_OASYS_SYSTEM_LIBRARIES AC_OASYS_SYSTEM_HEADERS AC_OASYS_SYSTEM_TYPES AC_OASYS_SYSTEM_FUNCTIONS AC_CHECK_HEADERS([sys/file.h termios.h]) AC_CHECK_FUNCS([select strpbrk]) AC_FUNC_SELECT_ARGTYPES dnl ------------------------------------------------------------------------- dnl Dump the autoconf cache now to try to avoid redundant checks dnl ------------------------------------------------------------------------- AC_CACHE_SAVE dnl ------------------------------------------------------------------------- dnl Checks for dependent third-party libraries dnl ------------------------------------------------------------------------- AC_OASYS_CONFIG_TCL AC_OASYS_CONFIG_STORAGE(required) AC_OASYS_CONFIG_GOOGLE_PERFTOOLS AC_OASYS_CONFIG_BLUEZ dnl ------------------------------------------------------------------------- dnl Output dnl ------------------------------------------------------------------------- dnl dnl We defer setting the various CFLAGS to avoid interfering with the dnl basic system tests. dnl CPPFLAGS="-I\$(SRCDIR)/servlib $CPPFLAGS $OASYS_CPPFLAGS $DTN_CPPFLAGS" LDFLAGS="$LDFLAGS $OASYS_LDFLAGS $DTN_LDFLAGS" LIBS="$LIBS $OASYS_LIBS $DTN_LIBS" AC_CONFIG_FILES(Rules.make:oasys/Rules.make.in) if test ! $SRCDIR = `pwd` ; then AC_CONFIG_FILES([Makefile:oasys/Makefile-Builddir.in]) AC_CONFIG_FILES([applib/Makefile:applib/Makefile-Builddir.in]) AC_CONFIG_FILES([servlib/Makefile:servlib/Makefile-Builddir.in]) AC_CONFIG_FILES([daemon/Makefile:daemon/Makefile-Builddir.in]) AC_CONFIG_FILES([apps/Makefile:apps/Makefile-Builddir.in]) AC_CONFIG_FILES([sim/Makefile:sim/Makefile-Builddir.in]) AC_CONFIG_FILES([test/Makefile:test/Makefile-Builddir.in]) fi dnl dnl Always reconfigure oasys as well dnl AC_CONFIG_SUBDIRS(oasys) AC_OUTPUT chmod oug-w Rules.make config.h config.h oasys/Rules.make oasys/config.h echo "DTN2 configure state:" echo "Target/Tools:" echo " TARGET is: $TARGET" echo " CC is: $CC (version $oasys_cv_prog_gccver)" echo " CXX is: $CXX" echo " " echo "Options:" echo " Debug: $DEBUG" echo " Optimize: $OPTIMIZE" echo " Static: $STATIC" echo " " echo "External packages:" echo " tcl: $oasys_cv_path_tcl_h/tcl.h -L$oasys_cv_path_tcl_lib -l$oasys_cv_lib_tcl" if test $LIBDB_ENABLED = 1 ; then echo " db: $oasys_cv_path_db_h/db.h -L$oasys_cv_path_db_lib -l$oasys_cv_lib_db" fi if test $POSTGRES_ENABLED = 1 ; then echo " postgres: $oasys_cv_path_postgres_h/libpq-fe.h -L $oasys_cv_path_postgres_lib -lpq" fi if test $MYSQL_ENABLED = 1 ; then if test "$ac_mysqldaemon" = "no" ; then echo " mysql: $oasys_cv_path_mysql_h/mysql.h -L $oasys_cv_path_mysql_lib -lmysqlclient" else echo " mysql: $oasys_cv_path_mysql_h/mysql.h -L $oasys_cv_path_mysql_lib -lmysqld" fi fi