diff options
author | Sebastian Reuße <seb@schattenkopie.de> | 2023-08-15 08:33:03 +0200 |
---|---|---|
committer | Sebastian Reuße <seb@schattenkopie.de> | 2023-08-15 08:37:46 +0200 |
commit | 922e463e3de6a0267a76574e8c5857de86d7f61a (patch) | |
tree | 2242f816b254c25e6faacc0a3e250ddb53e10cd0 /pkgs/applications/networking/p2p | |
parent | 2501addf2d61a3052128659883fee33435edd669 (diff) | |
download | nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar.gz nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar.bz2 nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar.lz nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar.xz nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.tar.zst nixpkgs-922e463e3de6a0267a76574e8c5857de86d7f61a.zip |
soulseekqt: don’t linger in a read-only directory after installing
It appears that the strip phase assumes that CWD is writable now (when using mktemp) and will otherwise fail with: mktemp: failed to create file via template 'striperr.XXXXXX': No such file or directory We now avoid this error by sticking to the build-directory and referencing files from the AppImage by path. References: #248569
Diffstat (limited to 'pkgs/applications/networking/p2p')
-rw-r--r-- | pkgs/applications/networking/p2p/soulseekqt/default.nix | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/pkgs/applications/networking/p2p/soulseekqt/default.nix b/pkgs/applications/networking/p2p/soulseekqt/default.nix index 3faf7ce6a76..9587bd0a930 100644 --- a/pkgs/applications/networking/p2p/soulseekqt/default.nix +++ b/pkgs/applications/networking/p2p/soulseekqt/default.nix @@ -28,24 +28,20 @@ mkDerivation rec { buildInputs = [ qtmultimedia stdenv.cc.cc ]; installPhase = '' - # directory in /nix/store so readonly - cd $appextracted - - binary="$(readlink AppRun)" + binary="$(realpath ${appextracted}/AppRun)" install -Dm755 $binary -t $out/bin # fixup and install desktop file desktop-file-install --dir $out/share/applications \ --set-key Exec --set-value $binary \ --set-key Comment --set-value "${meta.description}" \ - --set-key Categories --set-value Network default.desktop + --set-key Categories --set-value Network ${appextracted}/default.desktop mv $out/share/applications/default.desktop $out/share/applications/SoulseekQt.desktop - #TODO: write generic code to read icon path from $binary.desktop - icon="$(readlink .DirIcon)" + icon="$(realpath ${appextracted}/.DirIcon)" for size in 16 32 48 64 72 96 128 192 256 512 1024; do mkdir -p $out/share/icons/hicolor/"$size"x"$size"/apps - convert -resize "$size"x"$size" $icon $out/share/icons/hicolor/"$size"x"$size"/apps/$icon + convert -resize "$size"x"$size" $icon $out/share/icons/hicolor/"$size"x"$size"/apps/$(basename $icon) done ''; |