# -*- Autoconf -*- # Process this file with autoconf to produce a configure script. AC_PREREQ(2.57) AC_INIT([mysqlard], [1.0.0], [gert.dewit@sos.be]) AC_CONFIG_AUX_DIR([config]) AC_CONFIG_SRCDIR([src/main.c]) AM_CONFIG_HEADER([config.h]) AM_INIT_AUTOMAKE([mysqlard], [1.0.0]) # Checks for programs. AC_PROG_CC AC_PROG_LN_S AC_PATH_PROG(MV, mv, mv) AC_PATH_PROG(RM, rm, rm) AC_PATH_PROG(CP, cp, cp) AC_PATH_PROG(SED, sed, sed) AC_PATH_PROG(DATE, date, date) # Checks for libraries. # Checks for header files. AC_HEADER_DIRENT AC_HEADER_STDC AC_CHECK_HEADERS([string.h syslog.h unistd.h]) # Checks for typedefs, structures, and compiler characteristics. AC_C_CONST AC_TYPE_PID_T # Checks for library functions. AC_FUNC_FORK AC_FUNC_MALLOC AC_FUNC_VPRINTF AC_CHECK_FUNCS([strdup]) AC_CHECK_FUNCS([strtoull]) # permit --with-rrd= to specify rrd location AC_ARG_WITH(rrd, [ --with-rrd=PATH set the full path to your rrdtool installation.], [RRD_PATH="$withval"] [ if test "x$withval" != "xno" ; then LDFLAGS="-L${withval}/lib ${LDFLAGS}" CPPFLAGS="-I${withval}/include ${CPPFLAGS}" fi ] ) # permit --with-mysql= to specify mysql location AC_ARG_WITH(mysql, [ --with-mysql=PATH set the full path to your mysql installation.], [MYSQL_PATH="$withval"] [ if test "x$withval" != "xno" ; then LDFLAGS="-L${withval}/lib ${LDFLAGS}" CPPFLAGS="-I${withval}/include ${CPPFLAGS}" fi ] ) # My own checks. HAVE_RRD HAVE_MYSQL # My own variables RELEASE=1 AC_SUBST(RELEASE) AC_OUTPUT([Makefile src/Makefile man/Makefile])