AC_INIT(lucene4c, 0.04) AC_CONFIG_SRCDIR([src/store/istream.c]) AC_CONFIG_AUX_DIR(config) AM_INIT_AUTOMAKE(AC_PACKAGE_NAME, AC_PACKAGE_VERSION) AC_PROG_CC AM_PROG_CC_C_O AC_MSG_NOTICE([Apache Portable Runtime (APR) library configuration]) APR_FIND_APR("", "", 1, 1 0) if test $apr_found = "no"; then AC_MSG_ERROR([APR not found]) fi # just use APR's defaults for this stuff... CPPFLAGS="$CPPFLAGS `$apr_config --cppflags`" CFLAGS="$CFLAGS `$apr_config --cflags`" LDFLAGS="$LDLAGS `$apr_config --ldflags`" LCN_APR_LIBS="$LIBS `$apr_config --link-ld --libs`" LCN_APR_INCLUDES="`$apr_config --includes`" LIBTOOL="`$apr_config --apr-libtool`" AC_SUBST(LIBTOOL) AC_ARG_ENABLE(static, AC_HELP_STRING([--enable-static], [Build a static library and binaries.]), [ if test "$enableval" = "yes" ; then AM_CFLAGS="-static $AM_CFLAGS" fi ]) AC_SUBST(AM_CFLAGS) AC_ARG_ENABLE(maintainer-mode, AC_HELP_STRING([--enable-maintainer-mode], [Turn on debugging and extra compile time warnings]), [ if test "$enableval" = "yes" ; then if test "$GCC" = "yes"; then CFLAGS="$CFLAGS -Wall -Werror -Wpointer-arith -Wwrite-strings" fi CFLAGS="$CFLAGS -g" fi ]) AC_SUBST(ac_aux_dir) AC_SUBST(LCN_APR_INCLUDES) AC_SUBST(LCN_APR_LIBS) AC_OUTPUT([Makefile])