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

add -lstdc++ to CGO_LDFLAGS if a c++ extension is enabled #855

Merged
merged 1 commit into from
Jun 8, 2024

Conversation

DubbleClick
Copy link
Contributor

Unfortunately php --libs doesn't always list libstdc++ even if it's required for intl/icu. Therefore add -lstdc++ if a c++ extension is built on linux.

@dunglas
Copy link
Owner

dunglas commented Jun 7, 2024

Shouldn't this be fixed in static-php-cli instead? cc @crazywhalecc

@DubbleClick
Copy link
Contributor Author

Static-php-cli already compiles with -lstdc++ if they are added. The problem here is php-config not listing it, hence the CGO_LDFLAGS not containing it.

I guess we could manually patch the php-config file after spc finished running. At heart this is a libphp problem.

@dunglas
Copy link
Owner

dunglas commented Jun 8, 2024

Ok makes sense, thanks!

@dunglas dunglas merged commit acf6d0f into dunglas:main Jun 8, 2024
29 of 31 checks passed
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.

2 participants