Skip to content

Implement #70374: Update libtool #13476

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

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft

Implement #70374: Update libtool #13476

wants to merge 2 commits into from

Conversation

petk
Copy link
Member

@petk petk commented Feb 22, 2024

The libtool 1.5.26 is bundled with PHP since the very early days of the Autotools build system to ease the building process and avoid additional dependency on the system Libtool.

This updates the bundled libtool to current 2.4.7 version.

There were attempts to upgrade this tool in the past but we were concerned with too many failure possibilities at the time. I think PHP-8.4-dev is ready for this step today. It's actually not so much of a problem. Libtool is a very simple tool from the generated Makefile point of view - it generates the linking rules etc and it can be easily compared with the previous version from the Makefile directly. This is for now only in the draft PR phase, because I'll rebase the branch on the way and probably refactor more in the PR. This is just to get an overview.

petk added 2 commits March 21, 2024 06:53
The libtool 1.5.26 is bundled with PHP since the very early days of the
Autotools build system to ease the building process and avoid additional
dependency on the system Libtool.

This updates the bundled libtool to the current 2.4.7 version.

Fixes:

- Fixed race conditions when building PHP in parallel ("cannot create
  .libs" warnings).

Steps done:

```
git clone https://git.savannah.gnu.org/git/libtool.git
cd libtool
git checkout v2.4.7
./bootstrap
cp build-aux/ltmain.sh \
  m4/libtool.m4 \
  m4/lt\~obsolete.m4 \
  m4/ltoptions.m4 \
  m4/ltsugar.m4 \
  m4/ltversion.m4 \
  ../php-src/build/
```
This adds a simple shell script that copies Libtool generated files and
merges all M4 macro files to a single file libtool.m4 for convenience.
@petk petk changed the title Update libtool to 2.4.7 Implement #70374: Update libtool Mar 22, 2024
@petk
Copy link
Member Author

petk commented Jun 20, 2024

Just a quick update here. At the time of writing, there is Libtool 2.5.0 being rolled out and another update will soon followi this tag. It might take few months for this to happen as it's not uploaded yet to public servers or officially announced yet. The recent fixes that were added to the php-src forked/bundled libtool 1.5.26 will be included most likely in the 2.5.1. 🤞 (mainly those strict-prototypes warnings).

I'll recheck this and open a separate discussion when time is right for this. Hopefully, PHP-8.4 should get this bumped also in some way. Otherwise, the PHP version after the 8.4 definitely. Also there could be an optional "feature" in this PR also to patch the libtool using a .patch file to include critical updates if needed in the future.

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

Successfully merging this pull request may close these issues.

./configure error when building with NixOS
1 participant