feat: build PIE pre-packaged Linux binaries (glibc/musl) on release - #77
Merged
Conversation
Add a lightweight "builder" Docker stage (PHPIZE_DEPS + patch + zip,
independent of the heavy base stage) and a "pskel package" command that
builds the extension against the container PHP, smoke-tests that the
resulting shared object loads, and packages it using the same naming
convention as php/pie-ext-binary-builder:
php_{ext}-{tag}_php{maj.min}-{arch}-{os}-{libc}[-debug][-zts].zip
The Release workflow gains a Linux job (x86_64/arm64 x PHP 8.1-8.5 x
cli/zts x trixie/alpine = glibc and musl) uploading the archives as
release assets. Generated composer.json already declares
pre-packaged-binary in download-url-method, so PIE picks these up with
fallback to source builds.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
3 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
PIE supports
pre-packaged-binaryrelease assets for Linux/macOS (not just Windows), and pskel-generatedcomposer.jsonalready declares it indownload-url-method. This adds the Linux binary builds using the container infrastructure:builderstage derived directly from${IMAGE}:${TAG}— installs only$PHPIZE_DEPS+patch+zipand extracts the PHP source (for skeleton fallback init). No LLVM/Valgrind, so it builds in seconds.pskel package <release_tag> [output_dir] [extension_name]command — phpize/configure/make against the container PHP, verifies the built.soactually loads (php -m), and packages it with the exact naming convention of php/pie-ext-binary-builder:php_{ext}-{tag}_php{maj.min}-{arch}-{os}-{libc}[-debug][-zts].zip(NTS/nodebug omitted). Extension name resolves from argument →composer.json→config.m4. Also works on macOS hosts (darwin/bsdlibc).Linuxjob —ubuntu-24.04/-arm× PHP 8.1–8.5 × cli/zts × trixie/alpine (40 assets: glibc + musl, x86_64 + arm64) uploaded to the release.Test plan
php_skeleton-v9.9.9-test_php8.5-arm64-linux-glibc.zip(name auto-detected from composer.json via fallback init)php_skeleton-v9.9.9-test_php8.5-arm64-linux-musl-zts.zipskeleton.so; load smoke test passed in-container🤖 Generated with Claude Code