[PHP] Add Blueprint PHP extension loading step#3568
Draft
adamziel wants to merge 1 commit intocodex/unified-php-extension-loadingfrom
Draft
[PHP] Add Blueprint PHP extension loading step#3568adamziel wants to merge 1 commit intocodex/unified-php-extension-loadingfrom
adamziel wants to merge 1 commit intocodex/unified-php-extension-loadingfrom
Conversation
This was referenced Apr 29, 2026
38515ca to
cdbef2d
Compare
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.
What it does
Adds a
loadPHPExtensionBlueprint step on top of the runtime extension loader from #3566. Blueprints can now load either a direct.soresource or a compile-extensionmanifest.jsonresource, plus optional sidecar files throughextraFiles.This is the middle PR in the stack: #3566 runtime loader → this Blueprint step → #3567 compiler tools.
Rationale
The runtime PR gives Playground a shared
loadPHPExtension()API, but extenders also need a declarative Blueprint entry point. Keeping this in a stacked PR makes the runtime API reviewable on its own while preserving the same loading path for Blueprint users.Implementation
The step resolves
sourceas a normal Blueprint file resource, inferssourceFormatfrom.jsonvs.so, then calls@php-wasm/universal:{ "step": "loadPHPExtension", "source": { "resource": "url", "url": "https://example.com/extensions/example/manifest.json" }, "sourceFormat": "manifest" }literal:directoryis now recognized as a directory resource soextraFilescan carry data files or dependency assets. URL resources retain a non-enumerablesourceUrlso relative manifest artifacts can be resolved from the manifest URL.Testing instructions