about summary refs log tree commit diff
path: root/nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix')
-rw-r--r--nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix12
1 files changed, 4 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix b/nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix
index 3faf7ce6a76b..9587bd0a9304 100644
--- a/nixpkgs/pkgs/applications/networking/p2p/soulseekqt/default.nix
+++ b/nixpkgs/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
     '';