Skip to content

Commit d223cfb

Browse files
authored
parted: backport upstream C23 fix (#378578)
2 parents d6607ca + fa3cb96 commit d223cfb

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

pkgs/by-name/pa/parted/package.nix

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
lib,
33
stdenv,
44
fetchurl,
5+
fetchpatch,
56
lvm2,
67
libuuid,
78
gettext,
@@ -24,6 +25,15 @@ stdenv.mkDerivation rec {
2425
sha256 = "sha256-O0Pb4zzKD5oYYB66tWt4UrEo7Bo986mzDM3l5zNZ5hI=";
2526
};
2627

28+
patches = [
29+
# Fix the build against C23 compilers (like gcc-15):
30+
(fetchpatch {
31+
name = "c23.patch";
32+
url = "https://git.savannah.gnu.org/gitweb/?p=parted.git;a=patch;h=16343bda6ce0d41edf43f8dac368db3bbb63d271";
33+
hash = "sha256-8FgnwMrzMHPZNU+b/mRHCSu8sn6H7GhVLIhMUel40Hk=";
34+
})
35+
];
36+
2737
outputs = [
2838
"out"
2939
"dev"
@@ -46,6 +56,8 @@ stdenv.mkDerivation rec {
4656
++ lib.optional (lvm2 == null) "--disable-device-mapper"
4757
++ lib.optional enableStatic "--enable-static";
4858

59+
enableParallelBuilding = true;
60+
4961
# Tests were previously failing due to Hydra running builds as uid 0.
5062
# That should hopefully be fixed now.
5163
doCheck = !stdenv.hostPlatform.isMusl; # translation test

0 commit comments

Comments
 (0)