From a887cd983f8ccddbbf758f6f0418518a7ff9f138 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Cl=C3=A9ment?= Date: Fri, 2 Jan 2026 01:12:45 -0800 Subject: [PATCH] python314Packages.aardwolf: fix build failure PyO3 version did not supported python3.14 error: the configured Python interpreter version (3.14) is newer than PyO3's maximum supported version (3.13) = help: please check if an updated version of PyO3 is available. Current version: 0.23.5 = help: set PYO3_USE_ABI3_FORWARD_COMPATIBILITY=1 to suppress this check and build anyway using the stable ABI --- .../python-modules/aardwolf/default.nix | 12 +- .../python-modules/aardwolf/update-pyo3.patch | 111 ++++++++++++++++++ 2 files changed, 121 insertions(+), 2 deletions(-) create mode 100644 pkgs/development/python-modules/aardwolf/update-pyo3.patch diff --git a/pkgs/development/python-modules/aardwolf/default.nix b/pkgs/development/python-modules/aardwolf/default.nix index 13dcd2b84f8d..1ab694dc7652 100644 --- a/pkgs/development/python-modules/aardwolf/default.nix +++ b/pkgs/development/python-modules/aardwolf/default.nix @@ -33,10 +33,18 @@ buildPythonPackage rec { hash = "sha256-8QXPvfVeT3qadxTvt/LQX3XM5tGj6SpfOhP/9xcZHW4="; }; + patches = [ ./update-pyo3.patch ]; + cargoDeps = rustPlatform.fetchCargoVendor { - inherit pname version src; + inherit + pname + version + src + patches + ; sourceRoot = "${src.name}/aardwolf/utils/rlers"; - hash = "sha256-+2hENnrG35eRgQwtCCJUux9mYEkzD2astLgOqWHrH/M="; + hash = "sha256-n28jzS2+zbXsdR7rT0PBvcqNacuFMJKUug0mBYc4eFE="; + patchFlags = [ "-p4" ]; # strip i/aardwolf/utils/rlers/ prefix }; cargoRoot = "aardwolf/utils/rlers"; diff --git a/pkgs/development/python-modules/aardwolf/update-pyo3.patch b/pkgs/development/python-modules/aardwolf/update-pyo3.patch new file mode 100644 index 000000000000..777879277050 --- /dev/null +++ b/pkgs/development/python-modules/aardwolf/update-pyo3.patch @@ -0,0 +1,111 @@ +diff --git i/aardwolf/utils/rlers/Cargo.lock w/aardwolf/utils/rlers/Cargo.lock +index c287687..2fbd4a1 100644 +--- i/aardwolf/utils/rlers/Cargo.lock ++++ w/aardwolf/utils/rlers/Cargo.lock +@@ -1,6 +1,6 @@ + # This file is automatically @generated by Cargo. + # It is not intended for manual editing. +-version = 3 ++version = 4 + + [[package]] + name = "autocfg" +@@ -14,12 +14,6 @@ version = "1.5.0" + source = "registry+https://github.com/rust-lang/crates.io-index" + checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b" + +-[[package]] +-name = "cfg-if" +-version = "1.0.0" +-source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd" +- + [[package]] + name = "heck" + version = "0.5.0" +@@ -70,11 +64,10 @@ dependencies = [ + + [[package]] + name = "pyo3" +-version = "0.23.5" ++version = "0.27.2" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "7778bffd85cf38175ac1f545509665d0b9b92a198ca7941f131f85f7a4f9a872" ++checksum = "ab53c047fcd1a1d2a8820fe84f05d6be69e9526be40cb03b73f86b6b03e6d87d" + dependencies = [ +- "cfg-if", + "indoc", + "libc", + "memoffset", +@@ -88,19 +81,18 @@ dependencies = [ + + [[package]] + name = "pyo3-build-config" +-version = "0.23.5" ++version = "0.27.2" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "94f6cbe86ef3bf18998d9df6e0f3fc1050a8c5efa409bf712e661a4366e010fb" ++checksum = "b455933107de8642b4487ed26d912c2d899dec6114884214a0b3bb3be9261ea6" + dependencies = [ +- "once_cell", + "target-lexicon", + ] + + [[package]] + name = "pyo3-ffi" +-version = "0.23.5" ++version = "0.27.2" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "e9f1b4c431c0bb1c8fb0a338709859eed0d030ff6daa34368d3b152a63dfdd8d" ++checksum = "1c85c9cbfaddf651b1221594209aed57e9e5cff63c4d11d1feead529b872a089" + dependencies = [ + "libc", + "pyo3-build-config", +@@ -108,9 +100,9 @@ dependencies = [ + + [[package]] + name = "pyo3-macros" +-version = "0.23.5" ++version = "0.27.2" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "fbc2201328f63c4710f68abdf653c89d8dbc2858b88c5d88b0ff38a75288a9da" ++checksum = "0a5b10c9bf9888125d917fb4d2ca2d25c8df94c7ab5a52e13313a07e050a3b02" + dependencies = [ + "proc-macro2", + "pyo3-macros-backend", +@@ -120,9 +112,9 @@ dependencies = [ + + [[package]] + name = "pyo3-macros-backend" +-version = "0.23.5" ++version = "0.27.2" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "fca6726ad0f3da9c9de093d6f116a93c1a38e417ed73bf138472cf4064f72028" ++checksum = "03b51720d314836e53327f5871d4c0cfb4fb37cc2c4a11cc71907a86342c40f9" + dependencies = [ + "heck", + "proc-macro2", +@@ -161,9 +153,9 @@ dependencies = [ + + [[package]] + name = "target-lexicon" +-version = "0.12.16" ++version = "0.13.4" + source = "registry+https://github.com/rust-lang/crates.io-index" +-checksum = "61c41af27dd6d1e27b1b16b489db798443478cef1f06a660c96db617ba5de3b1" ++checksum = "b1dd07eb858a2067e2f3c7155d54e929265c264e6f37efe3ee7a8d1b5a1dd0ba" + + [[package]] + name = "unicode-ident" +diff --git i/aardwolf/utils/rlers/Cargo.toml w/aardwolf/utils/rlers/Cargo.toml +index d09de36..7f8ca8a 100644 +--- i/aardwolf/utils/rlers/Cargo.toml ++++ w/aardwolf/utils/rlers/Cargo.toml +@@ -17,5 +17,5 @@ crate-type = ["cdylib"] + path = "src/rle.rs" + + [dependencies] +-pyo3 = { version = "0.23.5", features = ["abi3"] } ++pyo3 = { version = "0.27.2", features = ["abi3"] } + byteorder = "1.4.3" +\ No newline at end of file