shivammathur / setup-php

GitHub action to set up PHP with extensions, php.ini configuration, coverage drivers, and various tools.
https://setup-php.com
MIT License
2.92k stars 341 forks source link

Unable to load dynamic library 'intl.so' #739

Closed ramsey closed 1 year ago

ramsey commented 1 year ago

Describe the bug

When I try installing the intl extension on PHP 8.2, I get the following error:

PHP Warning:  PHP Startup: Unable to load dynamic library 'intl.so' (tried: /usr/lib/php/20220829-zts/intl.so (/usr/lib/php/20220829-zts/intl.so: undefined symbol: executor_globals), /usr/lib/php/20220829-zts/intl.so.so (/usr/lib/php/20220829-zts/intl.so.so: cannot open shared object file: No such file or directory)) in Unknown on line 0

This issue sounds similar to #722, but I'm not sure if it's the same problem.

Version

Runners

Operating systems

PHP versions

To Reproduce

Here's the step I'm using in my GitHub Actions yml file:

      - name: "Install PHP"
        uses: "shivammathur/setup-php@2.25.2"
        with:
          php-version: "latest"
          extensions: "intl-73.1"
          coverage: "none"
        env:
          debug: true
          phpts: "ts"

Expected behavior

The intl extension should load.

Screenshots/Logs

Additional context

I've tried this with ICU version 67.1 and 73.1 (trying to see if maybe 67.1 had trouble on PHP 8.2).

You can see the failed runs for both, here:

Are you willing to submit a PR?

I'm willing to submit one if you give me a few pointers for where to get started. 🙂

shivammathur commented 1 year ago

Hi Ben, thanks for the sponsorship 🙂

I have added support for zts intl builds in https://github.com/shivammathur/setup-php/commit/12282c9597ef0c7329c0f382c5953c6248a43a62 and https://github.com/shivammathur/icu-intl/commit/d6ee42cd39943b532979d8f8ad6223042347b5cc.

This will be in the next release.

ramsey commented 1 year ago

Thanks!

shivammathur commented 1 year ago

Released 2.25.3 with the fix. https://github.com/shivammathur/setup-php/releases/tag/2.25.3