xref: /PHP-7.3/ext/simplexml/config.w32 (revision 8d3f8ca1)
1// vim:ft=javascript
2
3ARG_WITH("simplexml", "Simple XML support", "yes");
4
5if (PHP_SIMPLEXML == "yes") {
6	if(PHP_LIBXML == "yes" &&
7		ADD_EXTENSION_DEP('simplexml', 'libxml') &&
8		CHECK_HEADER_ADD_INCLUDE("libxml/tree.h", "CFLAGS_SIMPLEXML", PHP_PHP_BUILD + "\\include\\libxml2")
9	) {
10		EXTENSION("simplexml", "simplexml.c sxe.c");
11		AC_DEFINE("HAVE_SIMPLEXML", 1, "Simple XML support");
12		if (!PHP_SIMPLEXML_SHARED) {
13			ADD_FLAG("CFLAGS_SIMPLEXML", "/D LIBXML_STATIC");
14		} else {
15			if (!CHECK_LIB("libxml2.lib", "simplexml")) {
16				WARNING("simplexml support can't be enabled, libxml is not found")
17			}
18		}
19
20		if (!ADD_EXTENSION_DEP('simplexml', 'spl', true)) {
21			MESSAGE("\tSPL support in simplexml disabled");
22		}
23		ADD_FLAG("CFLAGS_SIMPLEXML", "/D PHP_SIMPLEXML_EXPORTS ");
24		PHP_INSTALL_HEADERS("ext/simplexml/", "php_simplexml.h php_simplexml_exports.h");
25	} else {
26		PHP_SIMPLEXML = "no";
27		WARNING("simplexml not enabled; libraries and headers not found");
28	}
29}
30