Skip to content
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

Fixes build-static script #1474

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

pierredup
Copy link
Contributor

Some small fixes for the build-static script (mostly issues when running the script multiple times)

  • If libphp is already built, spcCommand is not set and causes error when used
  • Don't error when trying to create static-php-cli directory if it already exists
  • spc-bin doesn't have an arm binary. If SPC_REL_TYPE is set to binary but the arch is arm64, don't download the binary and use source instead

@pierredup pierredup force-pushed the static-build-fixes branch from aebd9e6 to faa975c Compare March 31, 2025 19:35
cd static-php-cli/
curl -o spc -fsSL "https://dl.static-php.dev/static-php-cli/spc-bin/nightly/spc-linux-$(uname -m)"
curl -o spc -fsSL "https://dl.static-php.dev/static-php-cli/spc-bin/nightly/spc-linux-${arch}"
Copy link
Contributor

Choose a reason for hiding this comment

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

spc has arm binary, but it's using GNU-style arch name: aarch64, not arm64.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think this is still valid then. arch is set to uname -m at the top of the file, so we're just re-using the variable here. And if arch is set to arm64, then the download will fail since a binary with arm64 does not exist

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants