mirror of
https://github.com/NixOS/nixpkgs.git
synced 2026-03-08 03:24:06 +01:00
hfsutils: modernize
Signed-off-by: Ethan Carter Edwards <ethan@ethancedwards.com>
This commit is contained in:
parent
b34e3219f5
commit
aa5281f89b
1 changed files with 9 additions and 7 deletions
|
|
@ -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
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue