File: config.m4

package info (click to toggle)
php8.4 8.4.11-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 208,108 kB
  • sloc: ansic: 1,060,628; php: 35,345; sh: 11,866; cpp: 7,201; pascal: 4,913; javascript: 3,091; asm: 2,810; yacc: 2,411; makefile: 689; xml: 446; python: 301; awk: 148
file content (33 lines) | stat: -rw-r--r-- 949 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
PHP_ARG_ENABLE([xml],
  [whether to enable XML support],
  [AS_HELP_STRING([--disable-xml],
    [Disable XML support])],
  [yes])

PHP_ARG_WITH([expat],
  [whether to build with Expat support],
  [AS_HELP_STRING([--with-expat],
    [XML: use Expat library instead of libxml2 in the xml extension])],
  [no],
  [no])

if test "$PHP_XML" != "no"; then
  dnl Default to libxml2 if --with-expat is not specified.
  AS_VAR_IF([PHP_EXPAT], [no],
    [PHP_SETUP_LIBXML([XML_SHARED_LIBADD], [xml_extra_sources="compat.c"])],
    [PHP_SETUP_EXPAT([XML_SHARED_LIBADD])])

  PHP_NEW_EXTENSION([xml],
    [xml.c $xml_extra_sources],
    [$ext_shared],,
    [-DZEND_ENABLE_STATIC_TSRMLS_CACHE=1])

  AS_VAR_IF([PHP_EXPAT], [no], [
    PHP_ADD_EXTENSION_DEP(xml, libxml)
  ])

  PHP_SUBST([XML_SHARED_LIBADD])
  PHP_INSTALL_HEADERS([ext/xml], [expat_compat.h php_xml.h])
  AC_DEFINE([HAVE_XML], [1],
    [Define to 1 if the PHP extension 'xml' is available.])
fi