Skip to content

Rewrite to be based on php-build - #200

Open
Rusydy wants to merge 88 commits into
asdf-community:masterfrom
Rusydy:refactor-with-php-build
Open

Rusydy wants to merge 88 commits into
asdf-community:masterfrom
Rusydy:refactor-with-php-build

Conversation

@Rusydy

@Rusydy Rusydy commented Dec 11, 2025 •

Copy link
Copy Markdown
Contributor

TLDR; to solve #198, #72 and #194

This pull request introduces significant improvements to the PHP plugin's development workflow, documentation, and compatibility with modern dependencies. The most notable changes include a complete overhaul of the GitHub Actions CI workflow for better cross-platform and legacy PHP support, new documentation for manual local testing, compatibility patches for ICU 74 and libxml2 2.12, and a script for installing OpenSSL 1.1. Additionally, a new submodule for php-build is added to the repository.

CI/CD and Development Workflow Improvements

  • Major rewrite of .github/workflows/workflow.yml to use a single, matrix-based job supporting both Ubuntu and macOS, legacy and modern PHP versions, with improved dependency management and diagnostics. Adds linting and formatting jobs with more robust dependency installation and caching.
  • Adds vendor/php-build as a submodule, ensuring consistent build tooling. (.gitmodules)

Documentation Enhancements

  • Expands README.md with clearer installation, update, and usage instructions for the asdf PHP plugin.
  • Adds docs/local-testing-manually.md with detailed, step-by-step guides for installing, uninstalling, and troubleshooting various PHP versions locally, including custom build flags and log monitoring.

Compatibility and Build Fixes

  • Adds patch for PHP 7.4 to fix compatibility with ICU 74 (patches/php-7.4-icu-74-compat.patch).
  • Adds patch for PHP 8.0 to fix compatibility with ICU 74 (patches/php-8.0-icu-74-compat.patch).
  • Adds patch for PHP 8.0 to fix compatibility with libxml2 2.12 (patches/php-8.0-libxml2-2.12-compat.patch).

Utility Scripts

  • Introduces lib/install-openssl11.sh, a robust script for building and installing OpenSSL 1.1 locally, with dependency checks, colored output, and instructions for environment configuration.

Note

Modernizes the plugin around php-build, expanding CI/test coverage and improving legacy compatibility.

  • Add vendor/php-build submodule and bin/post-plugin-add to auto-initialize it; new bin/latest-stable for resolving latest
  • Rewrite bin/install to drive php-build, auto-detect/auto-install OpenSSL 1.1 (lib/install-openssl11.sh), set compilers/flags for legacy PHP, install Composer, optional Xdebug, and patch definitions for ICU 74 and libxml2 2.12
  • Add runtime env tweaks in bin/exec-env to set LD_LIBRARY_PATH for OpenSSL 1.1 when required
  • Overhaul CI workflow to a single matrix job across Ubuntu/macOS and legacy/modern versions; add lint and format jobs
  • Add compatibility patches: patches/php-7.4-icu-74-compat.patch, patches/php-8.0-icu-74-compat.patch, patches/php-8.0-libxml2-2.12-compat.patch
  • Update README.md and add docs/local-testing-manually.md; add .gitmodules and expand .gitignore

Written by Cursor Bugbot for commit 3492506. This will update automatically on new commits. Configure here.

@Rusydy
Rusydy requested a review from a team as a code owner December 11, 2025 08:09
@Rusydy
Rusydy marked this pull request as draft December 11, 2025 08:23
@Rusydy

Rusydy commented Dec 11, 2025

Copy link
Copy Markdown
Contributor Author

Waiting for php-build/php-build#796 to be approved by php-build's maintainer

@Rusydy

Rusydy commented Dec 17, 2025 •

Copy link
Copy Markdown
Contributor Author

Installation test of 7.4.14 on Almalinux 10

Screenshot 2025-12-17 at 22 26 39

Installation test of 8.0.0 on Almalinux 10

Screenshot 2025-12-17 at 21 26 22

Installation test of 8.3.29 on Almalinux 10

Screenshot 2025-12-26 at 04 12 28

@Rusydy
Rusydy marked this pull request as ready for review December 25, 2025 21:21
…d/compile

- Replace custom download and compilation logic with php-build
- Add automatic OpenSSL 1.1 compatibility detection and installation
- Add compiler warning fixes for modern GCC versions
- Add automated Composer installation with signature verification
- Add Xdebug installation support
- Add comprehensive patches for PHP 7.4 and 8.0 compatibility
- Add post-plugin-add hook for automatic php-build initialization
- Add latest-stable version resolution
- Add extensive documentation and testing instructions
- Add support for all php-build environment variables and options

This addresses build failures on modern systems and provides a more
maintainable and feature-rich PHP installation experience.
…9 examples

- Add comprehensive installation examples for latest stable version
- Include verbose installation options and custom compiler flags
- Add monitoring instructions with log file tailing
- Improve command consistency using 'asdf plugin add php $(pwd)'
- Document verification steps for successful installations
@Rusydy
Rusydy force-pushed the refactor-with-php-build branch from a1f1048 to 8e37fe6 Compare December 25, 2025 21:26
- Remove spaces around redirection operators (&>/dev/null, >/dev/null, >>, etc.)
- Conform to shfmt standard formatting rules (-s -i 2 -ci)
- Resolves CI format check failure
- Fix SC2155: Separate variable declaration and assignment to avoid masking return codes
- Fix SC2086: Add proper quoting for variables to prevent word splitting
- Fix SC2034: Remove unused php_status variable
- Apply fixes to bin/install and bin/exec-env
- All shellcheck warnings resolved while maintaining functionality
@Rusydy
Rusydy force-pushed the refactor-with-php-build branch from c70d153 to 3b506dd Compare December 25, 2025 22:01
Replace manual asdf/PHP setup with asdf-vm/actions/plugin-test and
remove ad-hoc asdf install and plugin steps. Add a non-fatal Composer
version check and initialize git submodules earlier, setting executable
permissions. Use asdf-vm/actions/setup and asdf-vm/actions/install to
provide shfmt, shellcheck and make, and simplify lint/format commands.
Use apt-get to install shellcheck and make and download shfmt v3.8.0
Drop asdf-vm actions from workflow
Provide giturl and gitref environment inputs so the PHP setup action can
access the current repository and checkout the exact commit.
Add asdf setup action and install the plugin from the current checkout,
then install and set the PHP version globally. Increase the test step
timeout to 30 minutes.
@Rusydy
Rusydy force-pushed the refactor-with-php-build branch 4 times, most recently from 9c7a281 to a2774e5 Compare December 26, 2025 02:31
@Rusydy
Rusydy force-pushed the refactor-with-php-build branch from 61240f5 to eced91b Compare October 11, 2026 08:58

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 1 file (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name=".github/workflows/workflow.yml">

<violation number="1" location=".github/workflows/workflow.yml:52">
P2: This adds a second identical Ubuntu `latest` matrix entry, so CI builds that configuration twice without adding coverage. Remove the duplicate entry.</violation>
</file>

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

- os: macos-latest
version: 7.4.14
is_legacy: true
- os: ubuntu-latest

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This adds a second identical Ubuntu latest matrix entry, so CI builds that configuration twice without adding coverage. Remove the duplicate entry.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At .github/workflows/workflow.yml, line 52:

<comment>This adds a second identical Ubuntu `latest` matrix entry, so CI builds that configuration twice without adding coverage. Remove the duplicate entry.</comment>

<file context>
@@ -46,13 +46,15 @@ jobs:
+          - os: macos-latest
+            version: 7.4.14
+            is_legacy: true
+          - os: ubuntu-latest
+            version: latest
+            is_legacy: false
</file context>

@Rusydy

Rusydy commented Oct 11, 2026 •

Copy link
Copy Markdown
Contributor Author
Screenshot 2026-10-11 at 16-10-49 Rewrite to be based on php-build · asdf-community_asdf-php@eced91b

thank god, finally

but I got a new issue

Screenshot 2026-10-11 at 16-27-28 Rewrite to be based on php-build · asdf-community_asdf-php@692adc7

@Rusydy

Rusydy commented Oct 11, 2026

Copy link
Copy Markdown
Contributor Author

all done!
Screenshot 2026-10-12 at 02-20-48 Rewrite to be based on php-build · asdf-community_asdf-php@7ff3e00

@Rusydy

Rusydy commented Oct 12, 2026

Copy link
Copy Markdown
Contributor Author

Now, I am testing it to my local mac and linux server
To really make sure all correct

@runephilosof

Copy link
Copy Markdown

The php-build rewrite drops the optional extensions on MacOS, though the README still says to brew install gmp libsodium.

On Linux, sodium was never enabled (#147), which breaks composer install for packages that need ext-sodium.

Could they be detected the way tidy already is?

pkg-config --exists libsodium && PHP_BUILD_CONFIGURE_OPTS+=" --with-sodium"

(I tested this against the current bin/install on Debian 12 with PHP 8.2.34.)

CI could also assert them in "Test PHP installation". php --ri exits 1 when an extension is missing:

for ext in openssl curl sodium; do php --ri "$ext" >/dev/null || exit 1; done

I have created Rusydy#1 with my suggestions

@Rusydy

Rusydy commented Oct 14, 2026

Copy link
Copy Markdown
Contributor Author

Hi @runephilosof

thank you for your suggestion
I will test it again

runephilosof and others added 2 commits October 20, 2026 20:15
php-build's default configure options include --with-bz2, so configure
fails with "Please reinstall the BZip2 distribution" without it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
php-build's default configure options include neither --with-sodium nor
--with-gmp, so installing libsodium or gmp had no effect, and
composer install fails for packages that require ext-sodium.

Add both flags when pkg-config finds the library, on Linux and macOS.
The flags take no DIR because PHP < 8.4 then looks for DIR/include/gmp.h,
which Debian's multiarch layout lacks. A sodium or gmp flag in
PHP_CONFIGURE_OPTIONS takes precedence.

CI installs both libraries and checks with php --ri that openssl, curl,
sodium and gmp are loaded.

Fixes asdf-community#147

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 issues found across 4 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="tests/install_optional_extensions.bats">

<violation number="1" location="tests/install_optional_extensions.bats:57">
P2: This assertion cannot verify that missing libraries add no configure flags because `run setup_optional_extensions` runs in a subshell and does not propagate `PHP_BUILD_CONFIGURE_OPTS` back to the test. Invoke the function directly while redirecting its output to a temporary file, then assert against the captured file and the updated variable.</violation>
</file>

<file name=".github/workflows/workflow.yml">

<violation number="1" location=".github/workflows/workflow.yml:22">
P1: The Ubuntu CI dependencies still omit `libbz2-dev`, so php-build's default `--with-bz2` configuration can fail with “Please reinstall the BZip2 distribution” before any Ubuntu matrix job completes. Add `libbz2-dev` to this package list.</violation>
</file>

Tip: Review your code locally with the cubic CLI to iterate faster.

View guided diff | Re-trigger cubic

version: ${{ matrix.php-version }}
env:
# Common dependencies for all builds
UBUNTU_DEPS: "autoconf bison build-essential curl gettext git libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libgmp-dev libreadline-dev libsodium-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev libtidy-dev openssl pkg-config re2c zlib1g-dev ca-certificates wget libtool automake gcc-9 g++-9 libxslt1.1 libxslt1-dev autotools-dev m4 libtool-bin"

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1: The Ubuntu CI dependencies still omit libbz2-dev, so php-build's default --with-bz2 configuration can fail with “Please reinstall the BZip2 distribution” before any Ubuntu matrix job completes. Add libbz2-dev to this package list.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At .github/workflows/workflow.yml, line 22:

<comment>The Ubuntu CI dependencies still omit `libbz2-dev`, so php-build's default `--with-bz2` configuration can fail with “Please reinstall the BZip2 distribution” before any Ubuntu matrix job completes. Add `libbz2-dev` to this package list.</comment>

<file context>
@@ -19,8 +19,8 @@ on:
   # Common dependencies for all builds
-  UBUNTU_DEPS: "autoconf bison build-essential curl gettext git libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libreadline-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev libtidy-dev openssl pkg-config re2c zlib1g-dev ca-certificates wget libtool automake gcc-9 g++-9 libxslt1.1 libxslt1-dev autotools-dev m4 libtool-bin"
-  MACOS_DEPS: "autoconf automake bison freetype gd gettext icu4c krb5 libedit libiconv libjpeg libpng libxml2 libzip openssl@3 pkg-config re2c zlib bzip2"
+  UBUNTU_DEPS: "autoconf bison build-essential curl gettext git libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libgmp-dev libreadline-dev libsodium-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev libtidy-dev openssl pkg-config re2c zlib1g-dev ca-certificates wget libtool automake gcc-9 g++-9 libxslt1.1 libxslt1-dev autotools-dev m4 libtool-bin"
+  MACOS_DEPS: "autoconf automake bison freetype gd gettext icu4c krb5 gmp libedit libiconv libjpeg libpng libsodium libxml2 libzip openssl@3 pkg-config re2c zlib bzip2"
 
</file context>
Suggested change
UBUNTU_DEPS: "autoconf bison build-essential curl gettext git libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libgmp-dev libreadline-dev libsodium-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev libtidy-dev openssl pkg-config re2c zlib1g-dev ca-certificates wget libtool automake gcc-9 g++-9 libxslt1.1 libxslt1-dev autotools-dev m4 libtool-bin"
UBUNTU_DEPS: "autoconf bison build-essential curl gettext git libbz2-dev libgd-dev libcurl4-openssl-dev libedit-dev libicu-dev libjpeg-dev libmysqlclient-dev libonig-dev libpng-dev libpq-dev libgmp-dev libreadline-dev libsodium-dev libsqlite3-dev libssl-dev libxml2-dev libzip-dev libtidy-dev openssl pkg-config re2c zlib1g-dev ca-certificates wget libtool automake gcc-9 g++-9 libxslt1.1 libxslt1-dev autotools-dev m4 libtool-bin"

@test "should report missing libraries and add no flags" {
export MOCK_PKG_CONFIG_PACKAGES=""

run setup_optional_extensions

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This assertion cannot verify that missing libraries add no configure flags because run setup_optional_extensions runs in a subshell and does not propagate PHP_BUILD_CONFIGURE_OPTS back to the test. Invoke the function directly while redirecting its output to a temporary file, then assert against the captured file and the updated variable.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At tests/install_optional_extensions.bats, line 57:

<comment>This assertion cannot verify that missing libraries add no configure flags because `run setup_optional_extensions` runs in a subshell and does not propagate `PHP_BUILD_CONFIGURE_OPTS` back to the test. Invoke the function directly while redirecting its output to a temporary file, then assert against the captured file and the updated variable.</comment>

<file context>
@@ -0,0 +1,81 @@
+@test "should report missing libraries and add no flags" {
+  export MOCK_PKG_CONFIG_PACKAGES=""
+
+  run setup_optional_extensions
+
+  [[ "$output" == *"libsodium not found"* ]]
</file context>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 3 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="docs/local-testing-manually.md">

<violation number="1" location="docs/local-testing-manually.md:5">
P3: Remove the trailing whitespace from the new heading and commands; it violates this repository's `.editorconfig` convention and makes `git diff --check` fail.</violation>
</file>

Tip: Get a Slack DM when cubic finishes reviewing your PRs. Connect Slack

View guided diff | Re-trigger cubic


Below are the steps to install different versions of PHP using asdf in local environment.

## install 8.5.11

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: Remove the trailing whitespace from the new heading and commands; it violates this repository's .editorconfig convention and makes git diff --check fail.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At docs/local-testing-manually.md, line 5:

<comment>Remove the trailing whitespace from the new heading and commands; it violates this repository's `.editorconfig` convention and makes `git diff --check` fail.</comment>

<file context>
@@ -2,13 +2,13 @@
 Below are the steps to install different versions of PHP using asdf in local environment.
 
-## install 8.5.4
+## install 8.5.11 
 
 ```bash
</file context>
Suggested change
## install 8.5.11
## install 8.5.11

Rusydy added 2 commits October 23, 2026 08:54
Use PHP's `extension_loaded` directly instead of piping `php -m`
through `grep -q`, and add regression tests for the pipefail behavior.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 2 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="tests/install_composer.bats">

<violation number="1" location="tests/install_composer.bats:1">
P2: This new Bats file is not run by the pull-request CI, so these Composer regression tests provide no automated protection. Add a CI step or job that invokes `make test` (or `bats tests/*.bats`).</violation>
</file>

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

@@ -0,0 +1,119 @@
#!/usr/bin/env bats

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2: This new Bats file is not run by the pull-request CI, so these Composer regression tests provide no automated protection. Add a CI step or job that invokes make test (or bats tests/*.bats).

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At tests/install_composer.bats, line 1:

<comment>This new Bats file is not run by the pull-request CI, so these Composer regression tests provide no automated protection. Add a CI step or job that invokes `make test` (or `bats tests/*.bats`).</comment>

<file context>
@@ -0,0 +1,119 @@
+#!/usr/bin/env bats
+
+# Tests for the extension checks at the top of install_composer(). Under pipefail, `php -m | grep -q`
</file context>

PHP 8.3.x does not build against openssl@4 headers. Point
PKG_CONFIG_PATH, LDFLAGS and
--with-openssl at openssl@3 when it is installed, unless an OpenSSL is
already chosen.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 2 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="tests/install_openssl.bats">

<violation number="1" location="tests/install_openssl.bats:48">
P3: This idempotency test never reaches the duplicate-config guard: the first call puts openssl@3 first in `PKG_CONFIG_PATH`, causing the second call to return earlier. Clear `PKG_CONFIG_PATH` between calls so the test also catches duplicate `--with-openssl` options.</violation>
</file>

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

install_fake_openssl3
link_openssl4

setup_openssl_pin

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: This idempotency test never reaches the duplicate-config guard: the first call puts openssl@3 first in PKG_CONFIG_PATH, causing the second call to return earlier. Clear PKG_CONFIG_PATH between calls so the test also catches duplicate --with-openssl options.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At tests/install_openssl.bats, line 48:

<comment>This idempotency test never reaches the duplicate-config guard: the first call puts openssl@3 first in `PKG_CONFIG_PATH`, causing the second call to return earlier. Clear `PKG_CONFIG_PATH` between calls so the test also catches duplicate `--with-openssl` options.</comment>

<file context>
@@ -0,0 +1,133 @@
+  install_fake_openssl3
+  link_openssl4
+
+  setup_openssl_pin
+
+  [[ "${PKG_CONFIG_PATH}" == "${TEST_TEMP_DIR}/opt/openssl@3/lib/pkgconfig"* ]]
</file context>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 issue found across 2 files (changes from recent commits).

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="README.md">

<violation number="1" location="README.md:46">
P3: `tidy` is not part of every default build: macOS enables it only when `tidy-html5` is installed, and legacy Linux builds explicitly disable it. Reword this as conditional support so users do not assume `ext/tidy` is present after following only the required dependencies.</violation>
</file>

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread README.md
`gmp` and `libsodium` are enabled automatically when pkg-config finds their libraries, on Linux and macOS. To skip one, add `--without-gmp` or `--without-sodium` to `PHP_CONFIGURE_OPTIONS`.

Composer is installed globally alongside PHP by default. If your application requires additional php extensions, you may need to install them via `pecl`. For example:
`tidy` is part of the default build. On macOS, install `tidy-html5`, or build without tidy by setting `PHP_CONFIGURE_OPTIONS="--without-tidy"`.

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P3: tidy is not part of every default build: macOS enables it only when tidy-html5 is installed, and legacy Linux builds explicitly disable it. Reword this as conditional support so users do not assume ext/tidy is present after following only the required dependencies.

Prompt for AI agents
Check if this issue is valid — if so, understand the root cause and fix it. When an issue isn't valid or won't be fixed in this PR, reply in its thread with the reason and then resolve the thread. At README.md, line 46:

<comment>`tidy` is not part of every default build: macOS enables it only when `tidy-html5` is installed, and legacy Linux builds explicitly disable it. Reword this as conditional support so users do not assume `ext/tidy` is present after following only the required dependencies.</comment>

<file context>
@@ -41,6 +41,10 @@ brew install autoconf automake bison freetype gd gettext icu4c krb5 \
 
+`gmp` and `libsodium` are enabled automatically when pkg-config finds their libraries, on Linux and macOS. To skip one, add `--without-gmp` or `--without-sodium` to `PHP_CONFIGURE_OPTIONS`.
+
+`tidy` is part of the default build. On macOS, install `tidy-html5`, or build without tidy by setting `PHP_CONFIGURE_OPTIONS="--without-tidy"`.
+
 ## Installation
</file context>
Suggested change
`tidy` is part of the default build. On macOS, install `tidy-html5`, or build without tidy by setting `PHP_CONFIGURE_OPTIONS="--without-tidy"`.
`tidy` is enabled when its library is available. On macOS, install `tidy-html5`, or build without tidy by setting `PHP_CONFIGURE_OPTIONS="--without-tidy"`.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

6 participants