]> granicus.if.org Git - php/commitdiff
Workaround for Informix set of libraries. One library depends on
authorSascha Schumann <sas@php.net>
Sun, 10 Oct 1999 17:12:23 +0000 (17:12 +0000)
committerSascha Schumann <sas@php.net>
Sun, 10 Oct 1999 17:12:23 +0000 (17:12 +0000)
another "library" (an object file). We build a standard library
out of this object here, so that we can link it in at the right place
later.

ext/informix/Makefile.am
ext/informix/config.m4

index 51337b0c0fde5dc70de72e4d74114545f3b94dee..89e65f2d30b279ed0ba6e4f95368e95d0bc7d0b2 100644 (file)
@@ -2,6 +2,9 @@
 
 INCLUDES=@INCLUDES@ -I@top_srcdir@ -I@top_srcdir@/libzend
 noinst_LTLIBRARIES=libphpext_informix.la
+noinst_LIBRARIES=libifx.a
+libifx_a_SOURCES=stub.c
+libifx_a_LIBADD=@IFX_OBJS@
 libphpext_informix_la_SOURCES=ifx.c
 libphpext_informix_la_LIBADD=@IFX_LIBS@
 
index 39164a628e0d7584b55cff68d53907d99f5aa239..21ad6ff27ba87cbab9226adc9b34722413cd72d6 100644 (file)
@@ -60,7 +60,16 @@ WARNING: You specified Informix base install directory that is different
       AC_DEFINE_UNQUOTED(IFX_VERSION, $IFX_VERSION)
       AC_MSG_RESULT(yes)
       PHP_EXTENSION(informix)
-      IFX_LIBS="$IFX_LFLAGS $IFX_LIBS"
+      for i in $IFX_LIBS; do
+        case "$i" in
+        *.o)
+            IFX_OBJS="$IFX_OBJS $i"
+            IFX_LIBADD="$IFX_LIBADD -Lext/informix -lifx";;
+        *)
+            IFX_LIBADD="$IFX_LIBADD $i";;
+        esac
+      done
+      IFX_LIBS="$IFX_LFLAGS $IFX_LIBADD"
       INCLUDES="$INCLUDES $IFX_INCLUDE"
     fi
   else
@@ -72,6 +81,7 @@ WARNING: You specified Informix base install directory that is different
 ])
 AC_SUBST(INFORMIXDIR)
 AC_SUBST(IFX_LIBS)
+AC_SUBST(IFX_OBJS)
        
 divert(5)