summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnatol Belski <ab@php.net>2015-03-23 14:43:56 +0100
committerAnatol Belski <ab@php.net>2015-03-23 15:09:07 +0100
commitc0adad555784a010c90530a138d678019f6e3394 (patch)
tree82cd9f258e5488c5fb70bf0e06ff92ee351c2978
parentffabfc703defe000438df1362b4743ec926577e8 (diff)
downloadphp-git-c0adad555784a010c90530a138d678019f6e3394.tar.gz
fix exports and shared compilation
-rw-r--r--ext/dom/config.w324
-rw-r--r--ext/dom/dom_ce.h61
-rw-r--r--ext/dom/php_dom.c62
3 files changed, 66 insertions, 61 deletions
diff --git a/ext/dom/config.w32 b/ext/dom/config.w32
index cbe15af1ab..0e8e12bb9a 100644
--- a/ext/dom/config.w32
+++ b/ext/dom/config.w32
@@ -18,6 +18,10 @@ if (PHP_DOM == "yes") {
if (!PHP_DOM_SHARED) {
ADD_FLAG("CFLAGS_DOM", "/D LIBXML_STATIC ");
+ } else {
+ if (!CHECK_LIB("libxml2.lib", "dom")) {
+ WARNING("dom support can't be enabled, libxml is not found")
+ }
}
PHP_INSTALL_HEADERS("ext/dom", "xml_common.h");
} else {
diff --git a/ext/dom/dom_ce.h b/ext/dom/dom_ce.h
index 2757d4bea5..b77ce0a31f 100644
--- a/ext/dom/dom_ce.h
+++ b/ext/dom/dom_ce.h
@@ -21,38 +21,39 @@
#ifndef DOM_CE_H
#define DOM_CE_H
-extern zend_class_entry *dom_domexception_class_entry;
-extern zend_class_entry *dom_domstringlist_class_entry;
-extern zend_class_entry *dom_namelist_class_entry;
-extern zend_class_entry *dom_domimplementationlist_class_entry;
-extern zend_class_entry *dom_domimplementationsource_class_entry;
-extern zend_class_entry *dom_domimplementation_class_entry;
-extern zend_class_entry *dom_documentfragment_class_entry;
-extern zend_class_entry *dom_document_class_entry;
-extern zend_class_entry *dom_nodelist_class_entry;
-extern zend_class_entry *dom_namednodemap_class_entry;
-extern zend_class_entry *dom_characterdata_class_entry;
-extern zend_class_entry *dom_attr_class_entry;
-extern zend_class_entry *dom_element_class_entry;
-extern zend_class_entry *dom_text_class_entry;
-extern zend_class_entry *dom_comment_class_entry;
-extern zend_class_entry *dom_typeinfo_class_entry;
-extern zend_class_entry *dom_userdatahandler_class_entry;
-extern zend_class_entry *dom_domerror_class_entry;
-extern zend_class_entry *dom_domerrorhandler_class_entry;
-extern zend_class_entry *dom_domlocator_class_entry;
-extern zend_class_entry *dom_domconfiguration_class_entry;
-extern zend_class_entry *dom_cdatasection_class_entry;
-extern zend_class_entry *dom_documenttype_class_entry;
-extern zend_class_entry *dom_notation_class_entry;
-extern zend_class_entry *dom_entity_class_entry;
-extern zend_class_entry *dom_entityreference_class_entry;
-extern zend_class_entry *dom_processinginstruction_class_entry;
-extern zend_class_entry *dom_string_extend_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_node_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domexception_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domstringlist_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_namelist_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domimplementationlist_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domimplementationsource_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domimplementation_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_documentfragment_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_document_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_nodelist_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_namednodemap_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_characterdata_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_attr_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_element_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_text_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_comment_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_typeinfo_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_userdatahandler_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domerror_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domerrorhandler_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domlocator_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_domconfiguration_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_cdatasection_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_documenttype_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_notation_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_entity_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_entityreference_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_processinginstruction_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_string_extend_class_entry;
#if defined(LIBXML_XPATH_ENABLED)
-extern zend_class_entry *dom_xpath_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_xpath_class_entry;
#endif
-extern zend_class_entry *dom_namespace_node_class_entry;
+extern PHP_DOM_EXPORT zend_class_entry *dom_namespace_node_class_entry;
#endif /* DOM_CE_H */
diff --git a/ext/dom/php_dom.c b/ext/dom/php_dom.c
index 9e174fe997..40109010f2 100644
--- a/ext/dom/php_dom.c
+++ b/ext/dom/php_dom.c
@@ -36,39 +36,39 @@
#define PHP_XPTR 2
/* {{{ class entries */
-zend_class_entry *dom_node_class_entry;
-zend_class_entry *dom_domexception_class_entry;
-zend_class_entry *dom_domstringlist_class_entry;
-zend_class_entry *dom_namelist_class_entry;
-zend_class_entry *dom_domimplementationlist_class_entry;
-zend_class_entry *dom_domimplementationsource_class_entry;
-zend_class_entry *dom_domimplementation_class_entry;
-zend_class_entry *dom_documentfragment_class_entry;
-zend_class_entry *dom_document_class_entry;
-zend_class_entry *dom_nodelist_class_entry;
-zend_class_entry *dom_namednodemap_class_entry;
-zend_class_entry *dom_characterdata_class_entry;
-zend_class_entry *dom_attr_class_entry;
-zend_class_entry *dom_element_class_entry;
-zend_class_entry *dom_text_class_entry;
-zend_class_entry *dom_comment_class_entry;
-zend_class_entry *dom_typeinfo_class_entry;
-zend_class_entry *dom_userdatahandler_class_entry;
-zend_class_entry *dom_domerror_class_entry;
-zend_class_entry *dom_domerrorhandler_class_entry;
-zend_class_entry *dom_domlocator_class_entry;
-zend_class_entry *dom_domconfiguration_class_entry;
-zend_class_entry *dom_cdatasection_class_entry;
-zend_class_entry *dom_documenttype_class_entry;
-zend_class_entry *dom_notation_class_entry;
-zend_class_entry *dom_entity_class_entry;
-zend_class_entry *dom_entityreference_class_entry;
-zend_class_entry *dom_processinginstruction_class_entry;
-zend_class_entry *dom_string_extend_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_node_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domexception_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domstringlist_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_namelist_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domimplementationlist_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domimplementationsource_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domimplementation_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_documentfragment_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_document_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_nodelist_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_namednodemap_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_characterdata_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_attr_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_element_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_text_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_comment_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_typeinfo_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_userdatahandler_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domerror_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domerrorhandler_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domlocator_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_domconfiguration_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_cdatasection_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_documenttype_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_notation_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_entity_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_entityreference_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_processinginstruction_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_string_extend_class_entry;
#if defined(LIBXML_XPATH_ENABLED)
-zend_class_entry *dom_xpath_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_xpath_class_entry;
#endif
-zend_class_entry *dom_namespace_node_class_entry;
+PHP_DOM_EXPORT zend_class_entry *dom_namespace_node_class_entry;
/* }}} */
zend_object_handlers dom_object_handlers;