From 1e2474b18ca97f75dcbe0b5ba78fa90dc8b0399d Mon Sep 17 00:00:00 2001 From: Stig Bakken Date: Sat, 17 Apr 1999 02:01:20 +0000 Subject: [PATCH] Apache module compiles again --- Makefile.in | 26 +++++++++++--------------- configure.in.in | 8 ++++++-- ext/gd/config.m4 | 4 ++-- libphp3.module.in | 2 +- scripts/armerge | 2 +- 5 files changed, 21 insertions(+), 21 deletions(-) diff --git a/Makefile.in b/Makefile.in index 9f9bde9f08..596380efbb 100644 --- a/Makefile.in +++ b/Makefile.in @@ -40,7 +40,10 @@ CC = @CC@ AR = ar rc BINNAME = @BINNAME@ INSTALL_IT = @INSTALL_IT@ -INCLUDE = -I$(srcdir) -I. -I$(ZEND_DIR) +EXTRA_LIBS = @EXTRA_LIBS@ +EXT_LIBS = @EXT_LIBS@ +INCLUDES = @INCLUDES@ +INCLUDE = -I$(srcdir) -I. -I$(ZEND_DIR) $(INCLUDES) PROF_CFLAGS = CFLAGS_SHLIB = @CFLAGS_SHLIB@ LDFLAGS_SHLIB = @LDFLAGS_SHLIB@ @@ -81,7 +84,7 @@ FUNCTIONS_SOURCE = functions/adabasd.c functions/apache.c functions/fhttpd.c \ FUNCTIONS = $(FUNCTIONS_SOURCE:.c=.o) PHPLIBS = -L@top_srcdir@/libzend -lzend -L@top_srcdir@/ext -lphpext -LIBS = $(PHPLIBS) @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @FHTTPD_LIB@ @DBASE_LIB@ @REGEX_LIB@ @DBM_LIB@ @ORACLE_LFLAGS@ @ORACLE_LIBS@ @IODBC_LFLAGS@ @IODBC_LIBS@ @SYBASE_LFLAGS@ @SYBASE_LIBS@ @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @MYSQL_LFLAGS@ @MYSQL_LIBS@ @MSQL_LFLAGS@ @MSQL_LIBS@ @ADA_LFLAGS@ @ADA_LIBS@ @SOLID_LIBS@ @EMPRESS_LIBS@ @OPENLINK_LFLAGS@ @OPENLINK_LIBS@ @PGSQL_LFLAGS@ @PGSQL_LIBS@ @LDAP_LFLAGS@ @LDAP_LIBS@ @VELOCIS_LIBS@ @CODBC_LFLAGS@ @CODBC_LIBS@ @IMAP_LIBS@ @ZLIB_LIBS@ @PDFLIB_LIBS@ @FDFLIB_LIBS@ @IFX_LFLAGS@ @IFX_LIBS@ @SNMP_LFLAGS@ @SNMP_LIBS@ @IBASE_LFLAGS@ @IBASE_LIBS@ @XML_LIBS@ @LIBS@ +LIBS = $(PHPLIBS) $(EXTRA_LIBS) @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @FHTTPD_LIB@ @DBASE_LIB@ @REGEX_LIB@ @DBM_LIB@ @ORACLE_LFLAGS@ @ORACLE_LIBS@ @IODBC_LFLAGS@ @IODBC_LIBS@ @SYBASE_LFLAGS@ @SYBASE_LIBS@ @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @MYSQL_LFLAGS@ @MYSQL_LIBS@ @MSQL_LFLAGS@ @MSQL_LIBS@ @ADA_LFLAGS@ @ADA_LIBS@ @SOLID_LIBS@ @EMPRESS_LIBS@ @OPENLINK_LFLAGS@ @OPENLINK_LIBS@ @PGSQL_LFLAGS@ @PGSQL_LIBS@ @LDAP_LFLAGS@ @LDAP_LIBS@ @VELOCIS_LIBS@ @CODBC_LFLAGS@ @CODBC_LIBS@ @IMAP_LIBS@ @ZLIB_LIBS@ @PDFLIB_LIBS@ @FDFLIB_LIBS@ @IFX_LFLAGS@ @IFX_LIBS@ @SNMP_LFLAGS@ @SNMP_LIBS@ @IBASE_LFLAGS@ @IBASE_LIBS@ @XML_LIBS@ @LIBS@ all: $(BINNAME) @@ -97,22 +100,15 @@ all-recursive clean-recursive distclean-recursive: php: all-recursive $(OBJS) $(FUNCTIONS) @REGEX_LIB@ @FHTTPD_LIB@ @DBASE_LIB@ $(CC) $(CFLAGS) -o $(BINNAME) $(LDFLAGS) $(OBJS) $(FUNCTIONS) $(LIBS) -# Apache 1.2 module -libphp3.a: all-recursive $(OBJS) $(FUNCTIONS) @DBASE_LIB@ - $(AR) $(BINNAME) $(OBJS) $(FUNCTIONS) @DBASE_LIB@ - $(RANLIB) $(BINNAME) - -# Apache 1.3 static module -libmodphp3.a: all-recursive $(OBJS) $(FUNCTIONS) @DBASE_LIB@ - $(AR) $(BINNAME) $(OBJS) $(FUNCTIONS) @DBASE_LIB@ +# Apache modules +libphp3.a libmodphp3.a libmodphp3-so.a: all-recursive $(OBJS) $(FUNCTIONS) + $(AR) $@.tmp $(OBJS) $(FUNCTIONS) @DBASE_LIB@ + scripts/armerge $@ $@.tmp ext/libphpext.a libzend/libzend.a + @rm -f $@.tmp $(RANLIB) $(BINNAME) # Apache 1.3 shared module -libmodphp3-so.a: all-recursive $(OBJS) $(FUNCTIONS) @DBASE_LIB@ - $(AR) libmodphp3-so.a $(OBJS) $(FUNCTIONS) @DBASE_LIB@ - $(RANLIB) libmodphp3-so.a - -libphp3.so: mod_php3.c libmodphp3-so.a +libphp3.so: $(srcdir)/mod_php3.c libmodphp3-so.a $(APXS) -c -o libphp3.so $(APXS_LDFLAGS) mod_php3.c libmodphp3-so.a regex/libregex.a: diff --git a/configure.in.in b/configure.in.in index bed2ce9431..96bf30c5e4 100644 --- a/configure.in.in +++ b/configure.in.in @@ -5,6 +5,8 @@ divert(0) recurse=yes for arg in $@; do case $arg in + ## This is to prevent "./config.status --recheck" from + ## running configure in libzend again. --no-recursion) recurse=no;; *) ;; esac @@ -332,7 +334,7 @@ AC_ARG_WITH(apxs, ]) -APACHE_INSTALL_FILES="$srcdir/mod_php3.* $srcdir/php_version.h libphp3.module $srcdir/libzend/libzend.a" +APACHE_INSTALL_FILES="$srcdir/mod_php3.* $srcdir/php_version.h libphp3.module" AC_MSG_CHECKING(for Apache module support via DSO through APACI) @@ -380,7 +382,7 @@ AC_ARG_WITH(shared-apache, fi fi INCLUDES="$INCLUDES $APACHE_INCLUDE" -dnl## AC_SUBST(APACHE_INCLUDE) + AC_SUBST(APACHE_INCLUDE) AC_SUBST(APACHE_TARGET) AC_SUBST(INSTALL_IT) AC_SUBST(BINNAME) @@ -841,6 +843,8 @@ AC_ARG_ENABLE(url-fopen-wrapper, divert(3) +AC_SUBST(EXTRA_LIBS) + # reading config stubs esyscmd(./scripts/config-stubs) diff --git a/ext/gd/config.m4 b/ext/gd/config.m4 index 16fdbd2bd1..7a2891ef03 100644 --- a/ext/gd/config.m4 +++ b/ext/gd/config.m4 @@ -49,6 +49,6 @@ if test "$ac_cv_lib_gd_gdImageLine" = "yes"; then fi AC_CHECK_LIB(ttf, TT_Open_Face) PHP_EXTENSION(gd) - LIBS="$LIBS $GD_LIBS" - INCLUDE="$INCLUDE $GD_INCLUDE" + EXTRA_LIBS="$EXTRA_LIBS $GD_LIBS" + INCLUDES="$INCLUDES $GD_INCLUDE" fi diff --git a/libphp3.module.in b/libphp3.module.in index 5ddff5b3e4..0e9028c81a 100644 --- a/libphp3.module.in +++ b/libphp3.module.in @@ -1,7 +1,7 @@ Name: php3_module ConfigStart RULE_WANTHSREGEX=@HSREGEX@ - LIBS="@PHP_LIBS@ @DBM_LIB@ @ORACLE_LFLAGS@ @ORACLE_LIBS@ @IODBC_LFLAGS@ @IODBC_LIBS@ @SYBASE_LFLAGS@ @SYBASE_LIBS@ @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @MYSQL_LFLAGS@ @MYSQL_LIBS@ @MSQL_LFLAGS@ @MSQL_LIBS@ @ADA_LFLAGS@ @ADA_LIBS@ @SOLID_LIBS@ @PGSQL_LFLAGS@ @PGSQL_LIBS@ @LDAP_LFLAGS@ @LDAP_LIBS@ @VELOCIS_LIBS@ @GD_LIBS@ @ZLIB_LIBS@ @CODBC_LFLAGS@ @CODBC_LIBS@ @IMAP_LIBS@ @IFX_LFLAGS@ @IFX_LIBS@ @SNMP_LFLAGS@ @SNMP_LIBS@ @IBASE_LFLAGS@ @IBASE_LIBS@ @PDFLIB_LIBS@ @XML_LIBS@ @LIBS@ @RDYNAMIC_LFLAGS@ $LIBS" + LIBS="@PHP_LIBS@ @EXTRA_LIBS@ @DBM_LIB@ @ORACLE_LFLAGS@ @ORACLE_LIBS@ @IODBC_LFLAGS@ @IODBC_LIBS@ @SYBASE_LFLAGS@ @SYBASE_LIBS@ @SYBASE_CT_LFLAGS@ @SYBASE_CT_LIBS@ @MYSQL_LFLAGS@ @MYSQL_LIBS@ @MSQL_LFLAGS@ @MSQL_LIBS@ @ADA_LFLAGS@ @ADA_LIBS@ @SOLID_LIBS@ @PGSQL_LFLAGS@ @PGSQL_LIBS@ @LDAP_LFLAGS@ @LDAP_LIBS@ @VELOCIS_LIBS@ @ZLIB_LIBS@ @CODBC_LFLAGS@ @CODBC_LIBS@ @IMAP_LIBS@ @IFX_LFLAGS@ @IFX_LIBS@ @SNMP_LFLAGS@ @SNMP_LIBS@ @IBASE_LFLAGS@ @IBASE_LIBS@ @PDFLIB_LIBS@ @XML_LIBS@ @LIBS@ @RDYNAMIC_LFLAGS@ $LIBS" RULE_HIDE=yes ConfigEnd diff --git a/scripts/armerge b/scripts/armerge index cda9d711cc..2c4df55e83 100755 --- a/scripts/armerge +++ b/scripts/armerge @@ -62,6 +62,6 @@ for archive in $in_archives; do ext_files="$ext_files $prefix$file" done fi - ar vr $out_archive $ext_files + ar r $out_archive $ext_files rm -f $ext_files done -- 2.40.0