From b527cf489200080c48dbc697589725c6b9214c6e Mon Sep 17 00:00:00 2001 From: FKouhai Date: Fri, 12 Jun 2026 23:24:40 +0200 Subject: [PATCH] fakeroot: fix build failure * update hash * add patch for missing wrapawk * should fix #531118 --- .../fa/fakeroot/add-missing-wrapawk.patch | 98 +++++++++++++++++++ pkgs/by-name/fa/fakeroot/package.nix | 3 +- 2 files changed, 100 insertions(+), 1 deletion(-) create mode 100644 pkgs/by-name/fa/fakeroot/add-missing-wrapawk.patch diff --git a/pkgs/by-name/fa/fakeroot/add-missing-wrapawk.patch b/pkgs/by-name/fa/fakeroot/add-missing-wrapawk.patch new file mode 100644 index 000000000000..ec1e7bef28ae --- /dev/null +++ b/pkgs/by-name/fa/fakeroot/add-missing-wrapawk.patch @@ -0,0 +1,98 @@ +--- /dev/null 2026-06-10 18:10:25.546025717 +0200 ++++ b/wrapawk 1970-01-01 01:00:01.000000000 +0100 +@@ -0,0 +1,95 @@ ++#Saluton Emacson! Bonvolu elekti -*- mode: awk; -*-. Dankon. ++ ++BEGIN{ ++ headerfile="wrapped.h"; ++ deffile="wrapdef.h"; ++ structfile="wrapstruct.h"; ++ tmpffile="wraptmpf.h"; ++ FS=";"; ++ WARNING="/* Automatically generated file. Do not edit. Edit wrapawk/wrapfunc.inp. */"; ++ print WARNING > headerfile; ++ print "#ifndef WRAPPED_H" > headerfile; ++ print "#define WRAPPED_H" > headerfile; ++ print WARNING > deffile; ++ print "#ifndef WRAPDEF_H" > deffile; ++ print "#define WRAPDEF_H" > deffile; ++ print WARNING > tmpffile; ++ print "#ifndef WRAPTMPF_H" > tmpffile; ++ print "#define WRAPTMPF_H" > tmpffile; ++ print WARNING > structfile; ++ print "#ifndef WRAPSTRUCT_H" > structfile; ++ print "#define WRAPSTRUCT_H" > structfile; ++ print "struct next_wrap_st next_wrap[]= {" > structfile; ++} ++ ++/\/\*/{ ++} ++/^(\#)/{ ++ print $0 > structfile; ++ print $0 > tmpffile; ++ print $0 > deffile; ++ print $0 > headerfile; ++ ++} ++/^[^\/].*;.*;.*;/{ ++ name=$1; ++ ret=$2; ++ argtype=$3; ++ argname=$4; ++ MACRO=$5; ++ openat_extra=$6; ++ if(openat_extra){ ++ print " {(void(*))&next_" name ", \"" name "\"}," > structfile; ++ print "extern " ret " (*next_" name ")" openat_extra ";" > headerfile; ++ print ret " (*next_" name ")" openat_extra "=tmp_" name ";"> deffile; ++ ++ print ret " tmp_" name, openat_extra "{" > tmpffile; ++ print " mode_t mode = 0;" > tmpffile; ++ print " if (flags & O_CREAT) {" > tmpffile; ++ print " va_list args;" > tmpffile; ++ print " va_start(args, flags);" > tmpffile; ++ print " mode = va_arg(args, int);" > tmpffile; ++ print " va_end(args);" > tmpffile; ++ print " }" > tmpffile; ++ print " load_library_symbols();" > tmpffile; ++ print " return next_" name, argname ";" > tmpffile; ++ print "}" > tmpffile; ++ print "" > tmpffile; ++ } else if(MACRO){ ++ print " {(void(*))&NEXT_" MACRO "_NOARG, " name "_QUOTE}," > structfile; ++ print "extern " ret " (*NEXT_" MACRO "_NOARG)" argtype ";" > headerfile; ++ print ret " (*NEXT_" MACRO "_NOARG)" argtype "=TMP_" MACRO ";"> deffile; ++ ++ print ret " TMP_" MACRO, argtype "{" > tmpffile; ++ print " load_library_symbols();" > tmpffile; ++ print " return NEXT_" MACRO "_NOARG " argname ";" > tmpffile; ++ print "}" > tmpffile; ++ print "" > tmpffile; ++ } else { ++ print " {(void(*))&next_" name ", \"" name "\"}," > structfile; ++ print "extern " ret " (*next_" name ")" argtype ";" > headerfile; ++ print ret " (*next_" name ")" argtype "=tmp_" name ";"> deffile; ++ ++ print ret " tmp_" name, argtype "{" > tmpffile; ++ print " load_library_symbols();" > tmpffile; ++ print " return next_" name, argname ";" > tmpffile; ++ print "}" > tmpffile; ++ print "" > tmpffile; ++ } ++} ++ ++/^ *$/{ ++ print > structfile; ++ print > headerfile; ++ print > deffile; ++ print > tmpffile; ++} ++ ++END{ ++ print " {NULL, NULL}," > structfile; ++ print "};" > structfile; ++ print "#endif" > structfile; ++ print "#endif" > tmpffile; ++ print "#endif" > deffile; ++ print "#endif" > headerfile; ++} diff --git a/pkgs/by-name/fa/fakeroot/package.nix b/pkgs/by-name/fa/fakeroot/package.nix index 401b39ab993c..993c57aab87f 100644 --- a/pkgs/by-name/fa/fakeroot/package.nix +++ b/pkgs/by-name/fa/fakeroot/package.nix @@ -22,10 +22,11 @@ stdenv.mkDerivation (finalAttrs: { repo = "fakeroot"; rev = "upstream/${finalAttrs.version}"; domain = "salsa.debian.org"; - hash = "sha256-1Xmb8OPZSVP4xtSBGuwwKwdVQXixEugMgQfvAJueJAg="; + hash = "sha256-sAzXeONjDT753lbu7amQY6yXpaTNCa4wFOzB01SRbCs="; }; patches = lib.optionals stdenv.hostPlatform.isLinux [ + ./add-missing-wrapawk.patch ./einval.patch ];