Skip to content

Autotools: Normalize PHP_INSTALL_HEADERS arguments #15620

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Aug 28, 2024

Conversation

petk
Copy link
Member

@petk petk commented Aug 28, 2024

The m4_normalize(m4_expand([...])) simplifies working with a list of header files. The m4_normalize() is at this point still used in the php-src config.m4 files because of copy/paste probability to community extensions where the arguments still need to be done in the old style to support phpize in PHP-8.3 and earlier. For example:

PHP_INSTALL_HEADERS([ext/dom], m4_normalize([
  dom_ce.h
  namespace_compat.h
  xml_common.h
  xpath_callbacks.h
]))

When PHP 8.4 will be the minimum supported PHP version, the headers can be installed without using m4_normalize() in PECL extensions. For example:

PHP_INSTALL_HEADERS([ext/dom], [
  dom_ce.h
  namespace_compat.h
  xml_common.h
  xpath_callbacks.h
])

The m4_normalize(m4_expand([...])) simplifies working with a list of
header files. The m4_normalize() is at this point still used in the
php-src config.m4 files because of copy/paste probability to community
extensions where the arguments still need to be done in the old style to
support phpize in PHP-8.3 and earlier. For example:

    PHP_INSTALL_HEADERS([ext/dom], m4_normalize([
      dom_ce.h
      namespace_compat.h
      xml_common.h
      xpath_callbacks.h
    ]))

When PHP 8.4 will be the minimum supported PHP version, the headers can
be installed without using m4_normalize() in PECL extensions. For
example:

    PHP_INSTALL_HEADERS([ext/dom], [
      dom_ce.h
      namespace_compat.h
      xml_common.h
      xpath_callbacks.h
    ])
@petk petk merged commit 0a0d2d0 into php:master Aug 28, 2024
9 of 10 checks passed
@petk petk deleted the patch-normalize-headers branch August 28, 2024 21:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants