pajoye          Tue Jul 15 16:47:40 2008 UTC

  Modified files:              
    /php-src/ext/dom    config.w32 
    /php-src/ext/libxml config.w32 
  Log:
  - MFB: do not enable libxml or dom when a dep/header/lib is missing
  
http://cvs.php.net/viewvc.cgi/php-src/ext/dom/config.w32?r1=1.3&r2=1.4&diff_format=u
Index: php-src/ext/dom/config.w32
diff -u php-src/ext/dom/config.w32:1.3 php-src/ext/dom/config.w32:1.4
--- php-src/ext/dom/config.w32:1.3      Mon Dec 22 13:16:39 2003
+++ php-src/ext/dom/config.w32  Tue Jul 15 16:47:40 2008
@@ -1,22 +1,26 @@
-// $Id: config.w32,v 1.3 2003/12/22 13:16:39 wez Exp $
+// $Id: config.w32,v 1.4 2008/07/15 16:47:40 pajoye Exp $
 // vim:ft=javascript
 
 ARG_WITH("dom", "DOM support", "yes");
 
 if (PHP_DOM == "yes" && PHP_LIBXML == "yes") {
-       EXTENSION("dom", "php_dom.c attr.c document.c domerrorhandler.c \
-               domstringlist.c domexception.c namelist.c 
processinginstruction.c \
-               cdatasection.c documentfragment.c domimplementation.c element.c 
\
-               node.c string_extend.c characterdata.c documenttype.c \
-               domimplementationlist.c entity.c nodelist.c text.c comment.c \
-               domconfiguration.c domimplementationsource.c entityreference.c \
-               notation.c xpath.c dom_iterators.c typeinfo.c domerror.c \
-               domlocator.c namednodemap.c userdatahandler.c");
-       AC_DEFINE("HAVE_DOM", 1, "DOM support");
-       if (!PHP_DOM_SHARED) {
-               ADD_FLAG("CFLAGS_DOM", "/D LIBXML_STATIC ");
+       if (PHP_LIBXML == "yes" && ADD_EXTENSION_DEP('dom', 'libxml')) {
+               EXTENSION("dom", "php_dom.c attr.c document.c domerrorhandler.c 
\
+                       domstringlist.c domexception.c namelist.c 
processinginstruction.c \
+                       cdatasection.c documentfragment.c domimplementation.c 
element.c \
+                       node.c string_extend.c characterdata.c documenttype.c \
+                       domimplementationlist.c entity.c nodelist.c text.c 
comment.c \
+                       domconfiguration.c domimplementationsource.c 
entityreference.c \
+                       notation.c xpath.c dom_iterators.c typeinfo.c 
domerror.c \
+                       domlocator.c namednodemap.c userdatahandler.c");
+               AC_DEFINE("HAVE_DOM", 1, "DOM support");
+               if (!PHP_DOM_SHARED) {
+                       ADD_FLAG("CFLAGS_DOM", "/D LIBXML_STATIC ");
+               }
+       } else {
+               WARNING("dom support can't be enabled, libxml is not enabled")
+               PHP_DOM = "no"
        }
-       ADD_EXTENSION_DEP('dom', 'libxml');
 }
 
 
http://cvs.php.net/viewvc.cgi/php-src/ext/libxml/config.w32?r1=1.10&r2=1.11&diff_format=u
Index: php-src/ext/libxml/config.w32
diff -u php-src/ext/libxml/config.w32:1.10 php-src/ext/libxml/config.w32:1.11
--- php-src/ext/libxml/config.w32:1.10  Wed May 14 03:32:27 2008
+++ php-src/ext/libxml/config.w32       Tue Jul 15 16:47:40 2008
@@ -1,4 +1,4 @@
-// $Id: config.w32,v 1.10 2008/05/14 03:32:27 auroraeosrose Exp $
+// $Id: config.w32,v 1.11 2008/07/15 16:47:40 pajoye Exp $
 // vim:ft=javascript
 
 ARG_WITH("libxml", "LibXML support", "yes");
@@ -6,7 +6,8 @@
 if (PHP_LIBXML == "yes") {
        if (CHECK_LIB("libxml2_a_dll.lib;libxml2_a.lib", "libxml") &&
                        
CHECK_LIB("libiconv_a.lib;iconv_a.lib;libiconv.lib;iconv.lib", "libxml") &&
-                       CHECK_HEADER_ADD_INCLUDE("libxml/parser.h", "CFLAGS")) {
+                       CHECK_HEADER_ADD_INCLUDE("libxml/parser.h", 
"CFLAGS_LIBXML") &&
+                       ADD_EXTENSION_DEP('libxml', 'iconv')) {
 
                EXTENSION("libxml", "libxml.c", false /* never shared */);
                AC_DEFINE("HAVE_LIBXML", 1, "LibXML support");
@@ -14,7 +15,9 @@
                if (!PHP_LIBXML_SHARED) {
                        ADD_DEF_FILE("ext\\libxml\\php_libxml2.def");
                }
-               ADD_EXTENSION_DEP('libxml', 'iconv');
+       } else {
+               WARNING("libxml support can't be enabled, iconv or libxml are 
missing")
+               PHP_LIBXML = "no"
        }
 }
 



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

Reply via email to