diff options
author | 7c6f434c <7c6f434c@mail.ru> | 2022-07-18 14:14:12 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-07-18 14:14:12 +0000 |
commit | 3aa086b0f0ef1c7e7a8239326bdecb16bc1c3b7f (patch) | |
tree | 723332ee54cde7e55c1fcb60320745d726e1bf5f /pkgs/games | |
parent | 2e6fbc1a8528376742cfae3ba396322aed7f630d (diff) | |
parent | 55a280290d9016d252edbf1055b9283d8a653b1e (diff) |
Merge pull request #181944 from tomfitzhenry/sgtpuzzles-cmake
sgtpuzzles: bump 2 years, and fix icons
Diffstat (limited to 'pkgs/games')
-rw-r--r-- | pkgs/games/sgt-puzzles/default.nix | 39 |
1 files changed, 16 insertions, 23 deletions
diff --git a/pkgs/games/sgt-puzzles/default.nix b/pkgs/games/sgt-puzzles/default.nix index 1c0b7aeda4938..7419b6810cb21 100644 --- a/pkgs/games/sgt-puzzles/default.nix +++ b/pkgs/games/sgt-puzzles/default.nix @@ -1,39 +1,38 @@ { lib, stdenv, fetchurl, desktop-file-utils -, gtk3, libX11 -, makeWrapper, pkg-config, perl, autoreconfHook, wrapGAppsHook +, gtk3, libX11, cmake, imagemagick +, pkg-config, perl, wrapGAppsHook }: stdenv.mkDerivation rec { pname = "sgt-puzzles"; - version = "20200610.9aa7b7c"; + version = "20220613.387d323"; src = fetchurl { url = "http://www.chiark.greenend.org.uk/~sgtatham/puzzles/puzzles-${version}.tar.gz"; - sha256 = "0rrd1c77ar91zqy4rr4xp1z7x3ywnshlac99cga4hnrgwb7vwl3f"; + hash = "sha256-Vcm7gxC9R7vvLkgkHblvEOONGLkYSHGMRfSBktgN/oQ="; }; sgt-puzzles-menu = fetchurl { - url = "https://raw.githubusercontent.com/Oleh-Kravchenko/portage/master/games-puzzle/sgt-puzzles/files/sgt-puzzles.menu"; + url = "https://raw.githubusercontent.com/gentoo/gentoo/720e614d0107e86fc1e520bac17726578186843d/games-puzzle/sgt-puzzles/files/sgt-puzzles.menu"; sha256 = "088w0x9g3j8pn725ix8ny8knhdsfgjr3hpswsh9fvfkz5vlg2xkm"; }; - nativeBuildInputs = [ autoreconfHook desktop-file-utils makeWrapper - pkg-config perl wrapGAppsHook ]; + nativeBuildInputs = [ + cmake + desktop-file-utils + imagemagick + perl + pkg-config + wrapGAppsHook + ]; buildInputs = [ gtk3 libX11 ]; - makeFlags = [ "prefix=$(out)" "gamesdir=$(out)/bin"]; - - preInstall = '' - mkdir -p "$out"/{bin,share/doc/sgtpuzzles} - cp gamedesc.txt LICENCE README "$out/share/doc/sgtpuzzles" - ''; - postInstall = '' for i in $(basename -s $out/bin/*); do ln -s $out/bin/$i $out/bin/sgt-puzzle-$i - install -Dm644 icons/$i-48d24.png -t $out/share/icons/hicolor/48x48/apps/ + install -Dm644 icons/$i-96d24.png -t $out/share/icons/hicolor/96x96/apps/ # Generate/validate/install .desktop files. echo "[Desktop Entry]" > $i.desktop @@ -43,7 +42,7 @@ stdenv.mkDerivation rec { --set-key Name --set-value $i \ --set-key Comment --set-value "${meta.description}" \ --set-key Categories --set-value "Game;LogicGame;X-sgt-puzzles;" \ - --set-key Icon --set-value $out/share/icons/hicolor/48x48/apps/$i-48d24 \ + --set-key Icon --set-value $out/share/icons/hicolor/96x96/apps/$i-96d24.png \ $i.desktop done @@ -57,16 +56,10 @@ stdenv.mkDerivation rec { install -Dm644 ${sgt-puzzles-menu} -t $out/etc/xdg/menus/applications-merged/ ''; - preConfigure = '' - perl mkfiles.pl - export NIX_LDFLAGS="$NIX_LDFLAGS -lX11" - export NIX_CFLAGS_COMPILE="$NIX_CFLAGS_COMPILE -Wno-error" - cp Makefile.gtk Makefile - ''; meta = with lib; { description = "Simon Tatham's portable puzzle collection"; license = licenses.mit; - maintainers = [ maintainers.raskin ]; + maintainers = with maintainers; [ raskin tomfitzhenry ]; platforms = platforms.linux; homepage = "https://www.chiark.greenend.org.uk/~sgtatham/puzzles/"; }; |