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

Upgrade to GNU Autoconf 2.72 #115765

Closed
2 tasks done
erlend-aasland opened this issue Feb 21, 2024 · 20 comments · Fixed by #128411 or #128502
Closed
2 tasks done

Upgrade to GNU Autoconf 2.72 #115765

erlend-aasland opened this issue Feb 21, 2024 · 20 comments · Fixed by #128411 or #128502
Assignees
Labels
build The build process and cross-build type-feature A feature request or enhancement

Comments

@erlend-aasland
Copy link
Contributor

erlend-aasland commented Feb 21, 2024

Feature or enhancement

Autoconf 2.72 was released 2023-12-22. Relevant highlights (some C&P verbatim) from the release announcement:

  • Pre-C89 compilers are no longer supported. This should not be a problem for us, as we're using C11.
  • AC_USE_SYSTEM_EXTENSIONS now enables C23 Annex F extensions
    by defining __STDC_WANT_IEC_60559_EXT__ (is this a problem?)
  • Autoconf now quotes 'like this' instead of `like this'; perhaps we should clean up our quoting in a separate first, so the 2.72 change is easier to review. <= not worth the churn
  • Improved compatibility with a wide variety of systems and tools
    including CheriBSD, Darwin (macOS), GNU Guix, OS/2, z/OS, Bash 5.2,
    the BusyBox shell and utilities, Clang/LLVM version 16, the upcoming
    GCC version 14, etc.

The other version requirements (Perl, M4, etc.) should not affect us.

Preliminary actions:

Linked PRs

@erlend-aasland erlend-aasland added type-feature A feature request or enhancement build The build process and cross-build labels Feb 21, 2024
@erlend-aasland erlend-aasland self-assigned this Feb 21, 2024
@erlend-aasland
Copy link
Contributor Author

The AC_CHECK_TYPE issue was addressed previously: #89886 (comment)

@erlend-aasland
Copy link
Contributor Author

cc. @corona10

@erlend-aasland
Copy link
Contributor Author

Seems our usage of AC_EGREP_*() is pretty safe, so it is not imperative to replace them with more modern equivalents.

@erlend-aasland
Copy link
Contributor Author

Seems our usage of AC_EGREP_*() is pretty safe, so it is not imperative to replace them with more modern equivalents.

Well, the AC_EGREP_HEADER usage is not very clean. We should fix that.

erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Feb 21, 2024
smontanaro pushed a commit to smontanaro/cpython that referenced this issue Feb 23, 2024
…onfigure.ac (pythonGH-115792)

Instead use AC_CHECK_TYPES.
(cherry picked from commit baae73d)

Co-authored-by: Erlend E. Aasland <[email protected]>
erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Feb 28, 2024
erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Feb 28, 2024
erlend-aasland added a commit that referenced this issue Feb 28, 2024
@erlend-aasland
Copy link
Contributor Author

Preparations for GNU Autoconf 2.72 have landed. It looks like Ubuntu 24.04 will ship with GNU Autoconf 2.71, though. @corona10, what do you think of switching to an autoconf docker/podman image again?

@corona10
Copy link
Member

corona10 commented Mar 1, 2024

@erlend-aasland

Preparations for GNU Autoconf 2.72 have landed. It looks like Ubuntu 24.04 will ship with GNU Autoconf 2.71, though. @corona10, what do you think of switching to an autoconf docker/podman image again?

  1. If we decide to use a container image, I would prefer to keep this strategy forever, even if OS provides the specific version.
  2. Let's migrate the repository https://github.com/corona10/cpython_autoconf to Python org and publish to the quary.io under python.org to provide images for x86 and aarch64. This repo publish the new image if the autoconf is bumped up :)
    see https://github.com/corona10/cpython_autoconf/blob/main/.github/workflows/manifest-build-push.yml

@erlend-aasland
Copy link
Contributor Author

erlend-aasland commented Mar 1, 2024

@corona10, IIRC one of the concerns with the container image, was that our CI relied on an external service; network issues or quay.io downtime can make jobs fail. If we go for such a solution, we should have a broader discussion.

@corona10
Copy link
Member

corona10 commented Mar 1, 2024

@corona10, IIRC one of the concerns with the container image, was that our CI relied on an external service; network issues or quary.io downtime can make jobs fail. If we go for such a solution, we should have a broader discussion.

@erlend-aasland
https://docs.github.com/en/packages/working-with-a-github-packages-registry/working-with-the-docker-registry
I didn't take a look at it deeply; If Github provide its own docker registry, it could be one option.
I feel(!) like that it's more reliable than quary.io since GitHub manages both of repository and registry from our side :)

@erlend-aasland
Copy link
Contributor Author

Looks promising!

@corona10
Copy link
Member

corona10 commented Mar 1, 2024

So, in this case, my suggestion would be.

  1. Create a GitHub repository for autoconf under python organization.
  2. Publish both of amd64 and arm64 images to the GitHub container registry :)

@erlend-aasland
Copy link
Contributor Author

Great; I say go for it 😀 let's propose it on Discourse.

@erlend-aasland
Copy link
Contributor Author

That would also make it easier for us to update the autoconf-archive macros.

@corona10
Copy link
Member

corona10 commented Mar 1, 2024

Here is my PoC

@corona10
Copy link
Member

corona10 commented Mar 1, 2024

PoC is not perfect but that’s why PoC :)

@erlend-aasland
Copy link
Contributor Author

Great; I say go for it 😀 let's propose it on Discourse.

👉 https://discuss.python.org/t/pinning-gnu-autotools-using-the-github-container-registry/47437

woodruffw pushed a commit to woodruffw-forks/cpython that referenced this issue Mar 4, 2024
woodruffw pushed a commit to woodruffw-forks/cpython that referenced this issue Mar 4, 2024
…ac (python#116016)

Rewrite using AX_CHECK_DEFINE and AC_CHECK_TYPES.
adorilson pushed a commit to adorilson/cpython that referenced this issue Mar 25, 2024
…ac (python#116016)

Rewrite using AX_CHECK_DEFINE and AC_CHECK_TYPES.
diegorusso pushed a commit to diegorusso/cpython that referenced this issue Apr 17, 2024
diegorusso pushed a commit to diegorusso/cpython that referenced this issue Apr 17, 2024
…ac (python#116016)

Rewrite using AX_CHECK_DEFINE and AC_CHECK_TYPES.
@erlend-aasland
Copy link
Contributor Author

A few months later, we've now got the CPython devcontainers 🥳 Switching to 2.72 should be pretty easy now. Let's do it now that we're in 3.14 alpha. I'll prepare a PR a week or so after landing #117815 (I'd like to let that PR live in main for a few days, in case anything breaks.

erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Nov 5, 2024
@erlend-aasland
Copy link
Contributor Author

erlend-aasland commented Nov 5, 2024

See erlend-aasland/cpython@859870a for a draft.

erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Jan 2, 2025
erlend-aasland added a commit to erlend-aasland/cpython that referenced this issue Jan 2, 2025
@erlend-aasland erlend-aasland linked a pull request Jan 2, 2025 that will close this issue
WolframAlph pushed a commit to WolframAlph/cpython that referenced this issue Jan 4, 2025
@erlend-aasland erlend-aasland reopened this Jan 4, 2025
@erlend-aasland
Copy link
Contributor Author

I forgot some doc and configure.ac updates; reopening.

@asottile
Copy link
Contributor

asottile commented Jan 8, 2025

so a bit annoyingly this now means that one cannot autoconf on the most popular linux distribution's most recent lts release (which isn't even that old) ubuntu 24.04 which ships with autoconf 2.71

this makes it difficult to package for deadsnakes as well -- I'm hoping to just patch out the autoconf version requirement and continue on as usual. it doesn't seem to actually need the most recent version?

@befeleme
Copy link
Contributor

Fedora 40, which is still a supported version, is also affected the same way (autoconf 2.71 still there).
@asottile, were you successful with patching out the autoconf version?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build The build process and cross-build type-feature A feature request or enhancement
Projects
None yet
4 participants