xref: /PHP-7.0/ext/libxml/config.w32 (revision becfdeb2)
1// $Id$
2// vim:ft=javascript
3
4ARG_WITH("libxml", "LibXML support", "yes");
5
6if (PHP_LIBXML == "yes") {
7	if (CHECK_LIB("libxml2_a_dll.lib;libxml2_a.lib", "libxml") &&
8			CHECK_LIB("libiconv_a.lib;iconv_a.lib;libiconv.lib;iconv.lib", "libxml") &&
9			CHECK_HEADER_ADD_INCLUDE("libxml/parser.h", "CFLAGS_LIBXML", PHP_PHP_BUILD + "\\include\\libxml2") &&
10			CHECK_HEADER_ADD_INCLUDE("libxml/tree.h", "CFLAGS_LIBXML", PHP_PHP_BUILD + "\\include\\libxml2") &&
11			ADD_EXTENSION_DEP('libxml', 'iconv')) {
12
13		EXTENSION("libxml", "libxml.c", false /* never shared */, "/DZEND_ENABLE_STATIC_TSRMLS_CACHE=1");
14		AC_DEFINE("HAVE_LIBXML", 1, "LibXML support");
15		ADD_FLAG("CFLAGS_LIBXML", "/D LIBXML_STATIC /D LIBXML_STATIC_FOR_DLL /D HAVE_WIN32_THREADS ");
16		if (!PHP_LIBXML_SHARED) {
17			ADD_DEF_FILE("ext\\libxml\\php_libxml2.def");
18		}
19		PHP_INSTALL_HEADERS("ext/libxml/", "php_libxml.h");
20	} else {
21		WARNING("libxml support can't be enabled, iconv or libxml are missing")
22		PHP_LIBXML = "no"
23	}
24}
25