From 0c653076dbc735757b84b2bc2ff9ee173c246b46 Mon Sep 17 00:00:00 2001 From: Edward Rudd Date: Mon, 22 Mar 2004 20:32:16 +0000 Subject: Fixed issue with different include directories for APR and APU. updated help screen after make install --- diff --git a/CHANGELOG b/CHANGELOG index 1ca523e..9d5087b 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -1,4 +1,8 @@ -$Id: CHANGELOG,v 1.17 2004/03/05 01:05:34 urkle Exp $ +$Id: CHANGELOG,v 1.18 2004/03/22 20:32:16 urkle Exp $ +?: ? +* fixed apache.m4 to work with apache 2 setups with different include + directories for APR and APU then core Apache + 1.96: 2004-03-04 * fixed LogSQLPreserveFile config parameter * reworked safe_create_tables and core SQL insert routine. diff --git a/Makefile.in b/Makefile.in index 65a0823..e45968b 100644 --- a/Makefile.in +++ b/Makefile.in @@ -16,7 +16,7 @@ CFLAGS = -Wc,-Wall -Wc,-Werror -Wc,-fno-strict-aliasing INCLUDES = @MYSQL_CFLAGS@ -LDADD = @MYSQL_LDFLAGS@ @MYSQL_LIBS@ +LDADD = @MYSQL_LDFLAGS@ @MYSQL_LIBS@ @RT_LIBS EXTRA_DIST = AUTHORS INSTALL TODO LICENSE CHANGELOG @@ -90,7 +90,21 @@ install: $(TARGETS) install-subdirs @@APXS_BIN@ -i $(TARGET); \ if test @WANT_SSL_MOD@ -eq 1; then \ @APXS_BIN@ -i $(sslTARGET); \ - fi + fi; \ + echo "*************************************************************************"; \ + echo "*** The mod_log_sql modules have been installed."; \ + echo "*** Please edit your Apache configuration files and"; \ + echo "*** add the appropriate LoadModule directives per the documentation"; \ + echo "*** in docs/manual.html"; \ + echo "*** If you have previously used 1.18 or lower then update you must change"; \ + echo "*** >LoadModule sql_log_module modules/mod_log_sql.so"; \ + echo "*** to"; \ + echo "*** >LoadModule log_sql_module modules/mod_log_sql.so"; \ + echo "*** in your httpd.conf as the internal name of the module has changed."; \ + echo "*** "; \ + echo "*** Also read the documentation about using SSL support and new "; \ + echo "*** configuration directives."; \ + echo "*************************************************************************"; activate: activate-subdirs @@APXS_BIN@ -i -a $(TARGET); \ diff --git a/configure.ac b/configure.ac index 9dcc71d..bf8ba6e 100644 --- a/configure.ac +++ b/configure.ac @@ -1,5 +1,5 @@ dnl Required initializer -AC_INIT(mod_log_sql, 1.96) +AC_INIT(mod_log_sql, 1.97) AC_PREREQ(2.53) AC_CONFIG_HEADERS(config.h) @@ -30,6 +30,19 @@ CHECK_PATH_MOD_SSL( AC_SUBST(WANT_SSL_MOD) +case "$target" in + *-*-solaris* | *-*-osf* ) + if test $APACHE_VERSION -eq 1.3; then + RTLIBS=-lrt + fi + ;; + *) + RTLIBS="" + ;; +esac + +AC_SUBST(RTLIBS) + AC_CHECK_HEADERS(limits.h) AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h]) @@ -47,5 +60,4 @@ if test $WANT_SSL_MOD -eq 1; then else AC_MSG_RESULT([SSL Support : no]) AC_MSG_RESULT([*** Use --enable-ssl to enable SSL support]) - AC_MSG_RESULT([*** and --with-ssl-inc for the directory for SSL headers]) fi diff --git a/m4/apache.m4 b/m4/apache.m4 index 3d76b72..ef9ce90 100644 --- a/m4/apache.m4 +++ b/m4/apache.m4 @@ -1,14 +1,17 @@ -dnl TEST_APACHE_VERSION([MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) +dnl TEST_APACHE_VERSION(RELEASE, [MINIMUM-VERSION [, ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]]) dnl Test for Apache dnl AC_DEFUN(TEST_APACHE_VERSION, [dnl AC_REQUIRE([AC_CANONICAL_TARGET]) - - min_apache_version="$1" + releasetest=$1 + min_apache_version="$2" no_apache="" ac_save_CFLAGS="$CFLAGS" CFLAGS="$CFLAGS $APACHE_CFLAGS" + if test $releasetest -eq 20; then + CFLAGS="$CFLAGS -I$APU_INCDIR -I$APR_INCDIR" + fi AC_TRY_RUN([ #include @@ -70,7 +73,7 @@ int main (int argc, char *argv[]) CFLAGS="$ac_save_CFLAGS" if test "x$no_apache" = x ; then - ifelse([$2], , :, [$2]) + ifelse([$3], , :, [$3]) else if test -f conf.apachetest ; then : @@ -90,7 +93,7 @@ int main(int argc, char *argv[]) [ echo "*** The test program failed to compile or link. Check config.log" ]) CFLAGS="$ac_save_CFLAGS" fi - ifelse([$3], , :, [$3]) + ifelse([$4], , :, [$4]) fi rm -f conf.apachetest ]) @@ -129,18 +132,24 @@ AC_ARG_ENABLE( AC_MSG_ERROR([*** your path, or use the --with-apxs configure option]) else APACHE_INCDIR=`$APXS_BIN -q INCLUDEDIR` - APACHE_CPPFLAGS=`$APXS_BIN -q CFLAGS` - APACHE_CFLAGS="-I$APACHE_INCDIR" + APR_INCDIR=`$APXS_BIN -q APR_INCLUDEDIR` + APU_INCDIR=`$APXS_BIN -q APU_INCLUDEDIR` + APACHE_CPPFLAGS=`$APXS_BIN -q CPPFLAGS` + APACHE_CPPFLAGS="$APACHE_CPPFLAGS -I$APACHE_INCDIR" + APACHE_CFLAGS=`$APXS_BIN -q CFLAGS` + APACHE_CFLAGS="$APACHE_CFLAGS -I$APACHE_INCDIR" APACHE_MODDIR=`$APXS_BIN -q LIBEXECDIR` if test "x$enable_apachetest" = "xyes" ; then if test "$min_apache20_version" != "no"; then AC_MSG_CHECKING(for Apache 2.0 version >= $min_apache20_version) - TEST_APACHE_VERSION($min_apache20_version, + TEST_APACHE_VERSION(20,$min_apache20_version, AC_MSG_RESULT(yes) AC_DEFINE(WITH_APACHE20,1,[Define to 1 if we are compiling with Apache 2.0.x]) - APACHE_VERSION="20" + APACHE_VERSION="2.0" APXS_EXTENSION=.la + APACHE_CFLAGS="$APACHE_CFLAGS -I$APU_INCDIR -I$APR_INCDIR" + APACHE_CPPFLAGS="$APACHE_CPPFLAGS -I$APU_INCDIR -I$APR_INCDIR" APACHE_DEFS="-DWITH_APACHE20" ifelse([$4], , , $4), AC_MSG_RESULT(no) @@ -151,10 +160,10 @@ AC_ARG_ENABLE( fi if test "$min_apache13_version" != "no" -a "x$APACHE_VERSION" = "x"; then AC_MSG_CHECKING(for Apache 1.3 version >= $min_apache13_version) - TEST_APACHE_VERSION($min_apache13_version, + TEST_APACHE_VERSION(13,$min_apache13_version, AC_MSG_RESULT(yes) AC_DEFINE(WITH_APACHE13,1,[Define to 1 if we are compiling with Apache 1.3.x]) - APACHE_VERSION="13" + APACHE_VERSION="1.3" APXS_EXTENSION=.so APACHE_CFLAGS="-g $APACHE_CFLAGS" APACHE_DEFS="-DWITH_APACHE13" @@ -168,6 +177,8 @@ AC_ARG_ENABLE( AC_SUBST(APACHE_CFLAGS) AC_SUBST(APACHE_CPPFLAGS) AC_SUBST(APACHE_INCDIR) + AC_SUBST(APR_INCDIR) + AC_SUBST(APU_INCDIR) AC_SUBST(APACHE_MODDIR) AC_SUBST(APACHE_VERSION) AC_SUBST(APXS_EXTENSION) -- cgit v0.9.2