diff options
-rw-r--r-- | CHANGELOG | 12 | ||||
-rw-r--r-- | Makefile.in | 3 | ||||
-rw-r--r-- | configure.ac | 11 | ||||
-rw-r--r-- | m4/apache.m4 | 10 | ||||
-rw-r--r-- | m4/mod_ssl.m4 | 43 | ||||
-rw-r--r-- | m4/mysql.m4 | 20 |
6 files changed, 80 insertions, 19 deletions
@@ -1,4 +1,4 @@ | |||
1 | $Id: CHANGELOG,v 1.4 2004/01/04 03:23:21 urkle Exp $ | 1 | $Id: CHANGELOG,v 1.5 2004/01/06 00:32:46 urkle Exp $ |
2 | 2 | ||
3 | TODO: | 3 | TODO: |
4 | * Port connection portion to other DBMS? Genericize the module? Start with | 4 | * Port connection portion to other DBMS? Genericize the module? Start with |
@@ -13,15 +13,19 @@ TODO: | |||
13 | * Directive to yes/no create ancillary tables (or just access table) | 13 | * Directive to yes/no create ancillary tables (or just access table) |
14 | * break module into separate code files | 14 | * break module into separate code files |
15 | separate DB implimentation into sub-modules via provider mechanism | 15 | separate DB implimentation into sub-modules via provider mechanism |
16 | separate module for SSL support | ||
16 | * add document building to Makefile.in | 17 | * add document building to Makefile.in |
17 | * backport patch for apache 1.3 | 18 | * backport patch for apache 1.3 |
18 | * investigate thread safety issues (libmysqlclient_r) | 19 | * investigate thread safety issues (libmysqlclient_r) |
19 | * Get SSL logging working with apache 2.0 | ||
20 | 20 | ||
21 | CHANGES: | 21 | CHANGES: |
22 | 1.92: ? | 22 | 1.92: 2004-01-05 |
23 | * fixed compilation issue with mysql 4.x where mysql_error returns const char * | 23 | * fixed compilation issue with mysql 4.x where mysql_error returns const char * |
24 | * added mysql import script by Aaron Jenson | 24 | * Have SSL support compiling (though not really tested) |
25 | * updated configure macros to detect mod_ssl.h | ||
26 | * configure now uses --with-apxs instead of --with-apache | ||
27 | * Added documentation from 1.19b (needs to be update) | ||
28 | * Fixed an issue with dependencies in Makefile.in | ||
25 | 29 | ||
26 | 1.91: 2003-12-23 | 30 | 1.91: 2003-12-23 |
27 | * Added checks for MySQL to autoconf | 31 | * Added checks for MySQL to autoconf |
diff --git a/Makefile.in b/Makefile.in index e3c7142..7c00d0a 100644 --- a/Makefile.in +++ b/Makefile.in | |||
@@ -112,7 +112,7 @@ $(builddir)/.deps: depend | |||
112 | 112 | ||
113 | depend: $(SOURCES) $(HEADERS) | 113 | depend: $(SOURCES) $(HEADERS) |
114 | if test -n "`ls $(srcdir)/*.c 2> /dev/null`"; then \ | 114 | if test -n "`ls $(srcdir)/*.c 2> /dev/null`"; then \ |
115 | $(CC) -MM -MT $(TARGET) -I@APACHE_INCDIR@ $(INCLUDES) -DHAVE_CONFIG_H $(srcdir)/*.c > $(builddir)/.deps || true; \ | 115 | $(CC) -MM -I@APACHE_INCDIR@ $(INCLUDES) -DHAVE_CONFIG_H $(srcdir)/*.c > $(builddir)/.deps || true; \ |
116 | fi | 116 | fi |
117 | 117 | ||
118 | include $(builddir)/.deps | 118 | include $(builddir)/.deps |
@@ -128,6 +128,7 @@ $(srcdir)/stamp-h.in: configure.ac aclocal.m4 | |||
128 | echo timestamp > $(srcdir)/stamp-h.in | 128 | echo timestamp > $(srcdir)/stamp-h.in |
129 | 129 | ||
130 | config.h: stamp-h | 130 | config.h: stamp-h |
131 | |||
131 | stamp-h: config.h.in config.status | 132 | stamp-h: config.h.in config.status |
132 | ./config.status | 133 | ./config.status |
133 | 134 | ||
diff --git a/configure.ac b/configure.ac index 84fbf96..ed8e25d 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1,5 +1,5 @@ | |||
1 | dnl Required initializer | 1 | dnl Required initializer |
2 | AC_INIT(mod_log_sql, 1.91) | 2 | AC_INIT(mod_log_sql, 1.92) |
3 | AC_PREREQ(2.53) | 3 | AC_PREREQ(2.53) |
4 | AC_CONFIG_HEADERS(config.h) | 4 | AC_CONFIG_HEADERS(config.h) |
5 | 5 | ||
@@ -17,6 +17,15 @@ CHECK_PATH_APACHE($APACHE_VERSION, | |||
17 | CHECK_PATH_MYSQL(:, | 17 | CHECK_PATH_MYSQL(:, |
18 | AC_MSG_ERROR([*** Mysql client libraries not found!]) | 18 | AC_MSG_ERROR([*** Mysql client libraries not found!]) |
19 | ) | 19 | ) |
20 | |||
21 | CHECK_PATH_MOD_SSL( | ||
22 | AC_DEFINE(WANT_SSL_LOGGING,,[Define if we want to compile in SSL support.]) | ||
23 | AC_MSG_WARN([*** Compilng with SSL support!]), | ||
24 | AC_MSG_WARN([*** Compiling without SSL support!]) | ||
25 | AC_MSG_WARN([*** enable with --enable-ssl to enable]) | ||
26 | AC_MSG_WARN([*** and --with-ssl-inc with the the directory for SSL headers]) | ||
27 | ) | ||
28 | |||
20 | AC_CHECK_HEADERS(limits.h) | 29 | AC_CHECK_HEADERS(limits.h) |
21 | 30 | ||
22 | AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h]) | 31 | AC_CONFIG_FILES([stamp-h], [echo timestamp > stamp-h]) |
diff --git a/m4/apache.m4 b/m4/apache.m4 index 8f0d200..1e29ac7 100644 --- a/m4/apache.m4 +++ b/m4/apache.m4 | |||
@@ -5,7 +5,7 @@ AC_DEFUN(CHECK_PATH_APACHE, | |||
5 | [dnl | 5 | [dnl |
6 | AC_ARG_WITH( | 6 | AC_ARG_WITH( |
7 | apxs, | 7 | apxs, |
8 | [AC_HELP_STRING([--with-apxs[=DIR]],[Location to APXS binary])], | 8 | [AC_HELP_STRING([--with-apxs=PATH],[Location to APXS binary (default: /usr)])], |
9 | apxs_prefix="$withval", | 9 | apxs_prefix="$withval", |
10 | apxs_prefix="/usr" | 10 | apxs_prefix="/usr" |
11 | ) | 11 | ) |
@@ -17,7 +17,11 @@ AC_ARG_ENABLE(apachetest, | |||
17 | 17 | ||
18 | AC_REQUIRE([AC_CANONICAL_TARGET]) | 18 | AC_REQUIRE([AC_CANONICAL_TARGET]) |
19 | PATH="$apxs_prefix:$apxs_prefix/bin:$apxs_prefix/sbin:$PATH" | 19 | PATH="$apxs_prefix:$apxs_prefix/bin:$apxs_prefix/sbin:$PATH" |
20 | AC_PATH_PROG(APXS_BIN, apxs, no, [$PATH]) | 20 | if test -x $apxs_prefix && test ! -d $apxs_prefix; then |
21 | APXS_BIN=$apxs_prefix | ||
22 | else | ||
23 | AC_PATH_PROG(APXS_BIN, apxs, no, [$PATH]) | ||
24 | fi | ||
21 | min_apache_version=ifelse([$1], ,1.3.1,$1) | 25 | min_apache_version=ifelse([$1], ,1.3.1,$1) |
22 | AC_MSG_CHECKING(for Apache - version >= $min_apache_version) | 26 | AC_MSG_CHECKING(for Apache - version >= $min_apache_version) |
23 | no_apxs="" | 27 | no_apxs="" |
@@ -96,7 +100,7 @@ int main (int argc, char *argv[]) | |||
96 | ifelse([$2], , :, [$2]) | 100 | ifelse([$2], , :, [$2]) |
97 | else | 101 | else |
98 | AC_MSG_RESULT(no) | 102 | AC_MSG_RESULT(no) |
99 | if test "APXS_BIN" = "no" ; then | 103 | if test "$APXS_BIN" = "no" ; then |
100 | echo "*** The apxs binary installed by apache could not be found" | 104 | echo "*** The apxs binary installed by apache could not be found" |
101 | echo "*** If apache is installed in PREFIX, make sure PREFIX/bin is in" | 105 | echo "*** If apache is installed in PREFIX, make sure PREFIX/bin is in" |
102 | echo "*** your path, or use the --with-apxs configure option" | 106 | echo "*** your path, or use the --with-apxs configure option" |
diff --git a/m4/mod_ssl.m4 b/m4/mod_ssl.m4 new file mode 100644 index 0000000..ddd910f --- /dev/null +++ b/m4/mod_ssl.m4 | |||
@@ -0,0 +1,43 @@ | |||
1 | dnl CHECK_PATH_MOD_SSL([ACTION-IF-FOUND [, ACTION-IF-NOT-FOUND]]) | ||
2 | dnl Test for mod_ssl and openssl header directory. | ||
3 | dnl | ||
4 | AC_DEFUN(CHECK_PATH_MOD_SSL, | ||
5 | [dnl | ||
6 | AC_ARG_ENABLE( | ||
7 | ssl, | ||
8 | [AC_HELP_STRING([--enable-ssl],[Compile in SSL support])], | ||
9 | ssl_val=yes, | ||
10 | ssl_val=no | ||
11 | ) | ||
12 | AC_ARG_WITH( | ||
13 | ssl-inc, | ||
14 | [AC_HELP_STRING([--with-ssl-inc=DIR],[Location of SSL header files])], | ||
15 | ssl_incdir="$withval", | ||
16 | ssl_incdir="/usr/include" | ||
17 | ) | ||
18 | |||
19 | if test "$ssl_val" = "yes"; then | ||
20 | ac_save_CFLAGS=$CFLAGS | ||
21 | ac_save_CPPFLAGS=$CPPFLAGS | ||
22 | MOD_SSL_CFLAGS="-I/usr/include/openssl $CFLAGS" | ||
23 | if test "x$ssl_incdir" != "x"; then | ||
24 | MOD_SSL_CFLAGS="-I$ssl_incdir -I$ssl_incdir/openssl $MOD_SSL_CFLAGS" | ||
25 | fi | ||
26 | |||
27 | CFLAGS="-I$APACHE_INCDIR $MOD_SSL_CFLAGS $CFLAGS" | ||
28 | CPPFLAGS="-I$APACHE_INCDIR $MOD_SSL_CFLAGS $CPPFLAGS" | ||
29 | AC_CHECK_HEADERS([mod_ssl.h], | ||
30 | mod_ssl_h=yes | ||
31 | ) | ||
32 | CFLAGS=$ac_save_CFLAGS | ||
33 | CPPFLAGS=$ac_save_CPPFLAGS | ||
34 | if test "x$mod_ssl_h" = "x"; then | ||
35 | ifelse([$2], , :, [$2]) | ||
36 | else | ||
37 | AC_SUBST(MOD_SSL_CFLAGS) | ||
38 | ifelse([$1], , :, [$1]) | ||
39 | fi | ||
40 | else | ||
41 | ifelse([$2], , :, [$2]) | ||
42 | fi | ||
43 | ]) | ||
diff --git a/m4/mysql.m4 b/m4/mysql.m4 index c4c4a3b..7892f88 100644 --- a/m4/mysql.m4 +++ b/m4/mysql.m4 | |||
@@ -19,18 +19,18 @@ AC_ARG_ENABLE( | |||
19 | ac_save_CFLAGS=$CFLAGS | 19 | ac_save_CFLAGS=$CFLAGS |
20 | ac_save_LDFLAGS=$LDFLAGS | 20 | ac_save_LDFLAGS=$LDFLAGS |
21 | if test "x$mysql_prefix" != "x" && test "x$mysql_prefix" != "xyes"; then | 21 | if test "x$mysql_prefix" != "x" && test "x$mysql_prefix" != "xyes"; then |
22 | MYSQL_LDFLAGS="-L${mysql_prefix}/lib -L${mysql_prefix}/lib/mysql -L${mysql_prefix}/mysql/lib" | 22 | MYSQL_LDFLAGS="-L${mysql_prefix}/lib -L${mysql_prefix}/lib/mysql -L${mysql_prefix}/mysql/lib" |
23 | MYSQL_CFLAGS="-I${mysql_prefix}/include -I${mysql_prefix}/include/mysql -I${mysql_prefix}/mysql/include" | 23 | MYSQL_CFLAGS="-I${mysql_prefix}/include -I${mysql_prefix}/include/mysql -I${mysql_prefix}/mysql/include" |
24 | else | 24 | else |
25 | MYSQL_LDFLAGS="-L/usr/local/mysql/lib -L/usr/lib/mysql -L/usr/mysql/lib -L/usr/local/lib/mysql -L/usr/local/mysql/lib/mysql -L/usr/mysql/lib/mysql" | 25 | MYSQL_LDFLAGS="-L/usr/local/mysql/lib -L/usr/lib/mysql -L/usr/mysql/lib -L/usr/local/lib/mysql -L/usr/local/mysql/lib/mysql -L/usr/mysql/lib/mysql" |
26 | MYSQL_CFLAGS="-I/usr/local/mysql/include -I/usr/include/mysql -I/usr/mysql/include -I/usr/local/include/mysql -I/usr/local/mysql/include/mysql -I/usr/mysql/include/mysql" | 26 | MYSQL_CFLAGS="-I/usr/local/mysql/include -I/usr/include/mysql -I/usr/mysql/include -I/usr/local/include/mysql -I/usr/local/mysql/include/mysql -I/usr/mysql/include/mysql" |
27 | fi | 27 | fi |
28 | CFLAGS="$CFLAGS $MYSQL_CFLAGS" | 28 | CFLAGS="$CFLAGS $MYSQL_CFLAGS" |
29 | LDFLAGS="$LDFLAGS $MYSQL_LDFLAGS" | 29 | LDFLAGS="$LDFLAGS $MYSQL_LDFLAGS" |
30 | AC_CHECK_LIB(m, floor) | 30 | AC_CHECK_LIB(m, floor) |
31 | AC_CHECK_LIB(z, gzclose) | 31 | AC_CHECK_LIB(z, gzclose) |
32 | with_mysql="yes" | 32 | with_mysql="yes" |
33 | AC_DEFINE(WITH_MYSQL,,[with mysql]) | 33 | AC_DEFINE(WITH_MYSQL,1,[Define to 1 if we are compiling with mysql]) |
34 | AC_CHECK_LIB(mysqlclient, mysql_init, , | 34 | AC_CHECK_LIB(mysqlclient, mysql_init, , |
35 | [AC_MSG_ERROR(libmysqlclient is needed for MySQL support)]) | 35 | [AC_MSG_ERROR(libmysqlclient is needed for MySQL support)]) |
36 | MYSQL_LIBS=$LIBS | 36 | MYSQL_LIBS=$LIBS |
@@ -48,14 +48,14 @@ AC_ARG_ENABLE( | |||
48 | CFLAGS=$ac_save_CFLAGS | 48 | CFLAGS=$ac_save_CFLAGS |
49 | LDFLAGS=$ac_save_LDFLAGS | 49 | LDFLAGS=$ac_save_LDFLAGS |
50 | if test "x$no_mysql" = x; then | 50 | if test "x$no_mysql" = x; then |
51 | AC_MSG_RESULT(yes) | 51 | AC_MSG_RESULT(yes) |
52 | ifelse([$1], , :, [$1]) | 52 | ifelse([$1], , :, [$1]) |
53 | else | 53 | else |
54 | AC_MSG_RESULT(no) | 54 | AC_MSG_RESULT(no) |
55 | echo "*** MySQL could not be found ***" | 55 | echo "*** MySQL could not be found ***" |
56 | MYSQL_CFLAGS="" | 56 | MYSQL_CFLAGS="" |
57 | MYSQL_LDFLAGS="" | 57 | MYSQL_LDFLAGS="" |
58 | MYSQL_LIBS="" | 58 | MYSQL_LIBS="" |
59 | ifelse([$2], , :, [$2]) | 59 | ifelse([$2], , :, [$2]) |
60 | fi | 60 | fi |
61 | AC_SUBST(MYSQL_LDFLAGS) | 61 | AC_SUBST(MYSQL_LDFLAGS) |