sniper          Mon Sep  9 14:17:11 2002 EDT

  Modified files:              
    /php4/ext/xslt      config.m4 
  Log:
  Version check for Sablotron.
  
  
Index: php4/ext/xslt/config.m4
diff -u php4/ext/xslt/config.m4:1.27 php4/ext/xslt/config.m4:1.28
--- php4/ext/xslt/config.m4:1.27        Wed Sep  4 14:47:25 2002
+++ php4/ext/xslt/config.m4     Mon Sep  9 14:17:11 2002
@@ -1,5 +1,5 @@
 dnl
-dnl $Id: config.m4,v 1.27 2002/09/04 18:47:25 sniper Exp $
+dnl $Id: config.m4,v 1.28 2002/09/09 18:17:11 sniper Exp $
 dnl
 dnl +------------------------------------------------------------------------------+
 dnl |  This is where the magic of the extension reallly is.  Depending on what     |
@@ -58,6 +58,30 @@
   fi
                                        
   if test "$PHP_XSLT_SABLOT" != "no"; then
+    AC_MSG_CHECKING([for Sablotron version])
+    old_CPPFLAGS=$CPPFLAGS
+    CPPFLAGS="$CPPFLAGS -I$XSLT_DIR/include"
+    AC_TRY_RUN([
+#include <stdlib.h>
+#include <sablot.h>
+
+int main ()
+{
+       double version;
+       version = atof(SAB_VERSION);
+       
+       if (version >= 0.96) {
+               exit(0);
+       }
+       exit(255);
+}
+    ],[
+      AC_MSG_RESULT([>= 0.96])
+    ],[
+      AC_MSG_ERROR([Sablotron version 0.96 or greater required.])
+    ])
+    CPPFLAGS=$old_CPPFLAGS
+
     found_expat=no
     for i in $PHP_EXPAT_DIR $XSLT_DIR /usr/local /usr; do
       if test -f $i/lib/libexpat.a -o -f $i/lib/libexpat.$SHLIB_SUFFIX_NAME; then



-- 
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to