From 551dfcc97ec5c21c03f7d234bfac71a4e34de066 Mon Sep 17 00:00:00 2001 From: Stefan Frijters Date: Mon, 23 Mar 2026 17:32:19 +0100 Subject: [PATCH 1/2] toybox: use structuredAttrs instead of passAsFile --- pkgs/by-name/to/toybox/package.nix | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/pkgs/by-name/to/toybox/package.nix b/pkgs/by-name/to/toybox/package.nix index 710a01b3f7d7..1f8c37ee822e 100644 --- a/pkgs/by-name/to/toybox/package.nix +++ b/pkgs/by-name/to/toybox/package.nix @@ -43,7 +43,6 @@ stdenv.mkDerivation (finalAttrs: { postPatch = "patchShebangs ."; inherit extraConfig; - passAsFile = [ "extraConfig" ]; configurePhase = '' make ${ @@ -57,7 +56,8 @@ stdenv.mkDerivation (finalAttrs: { "defconfig" } - cat $extraConfigPath .config > .config- + printf "%s" "$extraConfig" > .config- + cat .config >> .config- mv .config- .config make oldconfig @@ -87,6 +87,8 @@ stdenv.mkDerivation (finalAttrs: { env.NIX_CFLAGS_COMPILE = "-Wno-error"; + __structuredAttrs = true; + meta = { description = "Lightweight implementation of some Unix command line utilities"; homepage = "https://landley.net/toybox/"; From 0ccd178cdee69c41d299c61cdfb411c91c9a6f45 Mon Sep 17 00:00:00 2001 From: Stefan Frijters Date: Mon, 23 Mar 2026 17:32:53 +0100 Subject: [PATCH 2/2] toybox: use tag/hash instead of rev/sha256 --- pkgs/by-name/to/toybox/package.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pkgs/by-name/to/toybox/package.nix b/pkgs/by-name/to/toybox/package.nix index 1f8c37ee822e..b9f7c3fe57b8 100644 --- a/pkgs/by-name/to/toybox/package.nix +++ b/pkgs/by-name/to/toybox/package.nix @@ -22,8 +22,8 @@ stdenv.mkDerivation (finalAttrs: { src = fetchFromGitHub { owner = "landley"; repo = "toybox"; - rev = finalAttrs.version; - sha256 = "sha256-b5sigIxyg4T4wVc5z8Das+RdEXmNBPFsXpWwXxU/ERE="; + tag = finalAttrs.version; + hash = "sha256-b5sigIxyg4T4wVc5z8Das+RdEXmNBPFsXpWwXxU/ERE="; }; depsBuildBuild = optionals (stdenv.hostPlatform != stdenv.buildPlatform) [