From Fedora Project Wiki

Bump Minimum Rust Bindgen to v0.72

Summary

Fedora currently includes packages for v0.68, v0.69, v0.71, and v0.72 of the Rust "bindgen" crate. All dependent packages will be updated to use bindgen v0.72 (or newer) to address breaking changes in LLVM 22 that are only fixed in bindgen v0.72.1 and newer.

Owner

  • Name: Fabio Valentini
  • Email: decathorpe AT gmail DOT com
  • Name: Rust SIG
  • Email: rust AT lists DOT fedoraproject DOT org

Current status



Detailed Description

LLVM 22 brings (potentially breaking) changes to how clang represents parsed AST. This required changes in the bindgen crate, which have only been released in v0.72.1 and newer.

Older versions of the bindgen crate will potentially generate broken code with libclang 22, so all dependent packages in Fedora will be updated to use bindgen v0.72.1 or newer, and packages for old versions of bindgen will be retired from Fedora when they are no longer needed. This process has been ongoing for the past few months, but there are a few remaining packages that need to be handled:

Updating and / or patching packages that include "bindgen" in vendored Rust dependencies is explicitly out of scope of this Change.

Feedback

N/Y

Benefit to Fedora

Fedora packages are only built with versions of the "bindgen" crate that officially support LLVM 22 (not accounting for packages that build with vendored Rust dependencies).

Scope

  • Proposal owners:
    • Submit packaging changes (and upstream pull requests) for updating the "bindgen" dependency, where necessary.
    • Submit pull requests for packages not under the Rust SIG umbrella (clamav, retis, kryoptic).
  • Other developers:
    • Merge + build pull requests and / or rely on provenpackagers to merge + build pull requests for packages not under the Rust SIG umbrella.
  • Release engineering: N/A
  • Policies and guidelines: N/A
  • Trademark approval: N/A
  • Alignment with the Fedora Strategy: N/A

Upgrade/compatibility impact

There should be no upgrade / compatibility impact, other than improved support for building Rust packages when using LLVM 22 - the default version of LLVM in Fedora 44.

Early Testing (Optional)

N/A

Do you require 'QA Blueprint' support? N

How To Test

  • Check that all packages that depend on "crate(bindgen)" are built with bindgen v0.72.1 or newer.
  • Verify that packages for older versions of the "bindgen" crate were retired from Fedora 44+.

User Experience

No change in user experience (not a user-facing change).

Dependencies

Three dependent packages are not co-maintained by the Rust SIG (clamav, retis, kryoptic). Maintainers of these packages (or provenpackagers) will need to merge pull requests and / or implement necessary changes themselves.

Contingency Plan

If packages cannot be ported to bindgen v0.72 in time for the final freeze, retirement of older bindgen versions can be postponed to later versions of Fedora, as necessary. Not all packages will be affected by the changes in LLVM 22.

  • Contingency mechanism: Postpone retirement of old bindgen versions to a later Fedora release.
  • Contingency deadline: Final freeze.
  • Blocks release? No / N/A (not a System Wide Change)

Documentation

Release Notes

The minimum version of the "bindgen" crate in Fedora has been raised to v0.72.1 to address compatibility issues with LLVM 22.