From aa5281f89b0494a3baae3598a6ec0040faa89e77 Mon Sep 17 00:00:00 2001 From: Ethan Carter Edwards Date: Wed, 11 Feb 2026 09:27:51 -0500 Subject: [PATCH] hfsutils: modernize Signed-off-by: Ethan Carter Edwards --- pkgs/by-name/hf/hfsutils/package.nix | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/pkgs/by-name/hf/hfsutils/package.nix b/pkgs/by-name/hf/hfsutils/package.nix index ad5abaf72f3f..9604a28eef76 100644 --- a/pkgs/by-name/hf/hfsutils/package.nix +++ b/pkgs/by-name/hf/hfsutils/package.nix @@ -5,9 +5,10 @@ fetchDebianPatch, testers, autoreconfHook, - bash, + bashNonInteractive, tcl, tk, + writableTmpDirAsHomeHook, }: stdenv.mkDerivation (finalAttrs: { @@ -75,14 +76,14 @@ stdenv.mkDerivation (finalAttrs: { ]; buildInputs = [ - bash # allow /bin/sh shebang in hfs to get patched during fixupPhase + bashNonInteractive # allow /bin/sh shebang in hfs to get patched during fixupPhase tcl tk ]; configureFlags = [ - (lib.strings.withFeatureAs true "tcl" "${tcl}") - (lib.strings.withFeatureAs true "tk" "${tk}") + (lib.strings.withFeatureAs true "tcl" tcl) + (lib.strings.withFeatureAs true "tk" tk) ]; # Tcl code doesn't pass const strings to API @@ -97,6 +98,10 @@ stdenv.mkDerivation (finalAttrs: { doInstallCheck = stdenv.buildPlatform.canExecute stdenv.hostPlatform; + nativeInstallCheckInputs = [ + writableTmpDirAsHomeHook # current volume is tracked in $HOME/.hcwd + ]; + installCheckPhase = let diskLabel = "Test Disk"; @@ -104,9 +109,6 @@ stdenv.mkDerivation (finalAttrs: { '' runHook preInstallCheck - # current volume is tracked in $HOME/.hcwd - export HOME=$(mktemp -d) - # Allow pipeline to fail here set +o pipefail yes | head -c 819200 > disk.hfs