parted: backport upstream C23 fix

Without the change the build against c23 compiler (like `gcc-15`) fails as:

    parted> parted.c: In function '_init_commands':
    parted> parted.c:2469:9: error: passing argument 2 of 'command_create' from incompatible pointer type []
    parted>  2469 |         do_version,
    parted>       |         ^~~~~~~~~~
    parted>       |         |
    parted>       |         int (*)(void)
This commit is contained in:
Sergei Trofimovich
2025-02-01 16:54:01 +00:00
parent 247b802773
commit 926bb4273e
+10
View File
@@ -2,6 +2,7 @@
lib,
stdenv,
fetchurl,
fetchpatch,
lvm2,
libuuid,
gettext,
@@ -24,6 +25,15 @@ stdenv.mkDerivation rec {
sha256 = "sha256-O0Pb4zzKD5oYYB66tWt4UrEo7Bo986mzDM3l5zNZ5hI=";
};
patches = [
# Fix the build against C23 compilers (like gcc-15):
(fetchpatch {
name = "c23.patch";
url = "https://git.savannah.gnu.org/gitweb/?p=parted.git;a=patch;h=16343bda6ce0d41edf43f8dac368db3bbb63d271";
hash = "sha256-8FgnwMrzMHPZNU+b/mRHCSu8sn6H7GhVLIhMUel40Hk=";
})
];
outputs = [
"out"
"dev"