From 43e13111c6803551751d76a8adb9472f6f14f9c8 Mon Sep 17 00:00:00 2001 From: hulr Date: Sat, 1 Jul 2023 23:13:34 +0200 Subject: [PATCH] stone-kingdoms: init at 0.5.0 https://gitlab.com/stone-kingdoms/stone-kingdoms/-/tags/0.5.0 --- pkgs/games/stone-kingdoms/default.nix | 63 +++++++++++++++++++++++++++ pkgs/top-level/all-packages.nix | 2 + 2 files changed, 65 insertions(+) create mode 100644 pkgs/games/stone-kingdoms/default.nix diff --git a/pkgs/games/stone-kingdoms/default.nix b/pkgs/games/stone-kingdoms/default.nix new file mode 100644 index 000000000000..e49db727b9e8 --- /dev/null +++ b/pkgs/games/stone-kingdoms/default.nix @@ -0,0 +1,63 @@ +{ lib +, stdenvNoCC +, fetchFromGitLab +, copyDesktopItems +, love +, makeDesktopItem +, makeWrapper +, strip-nondeterminism +, zip +}: + +stdenvNoCC.mkDerivation rec { + pname = "stone-kingdoms"; + version = "0.5.0"; + + src = fetchFromGitLab { + owner = "stone-kingdoms"; + repo = pname; + rev = version; + hash = "sha256-FQrg/1/nfFC/irCWSLbnb9GYSUv//ovvcjzvIg94oEI="; + }; + + nativeBuildInputs = [ + copyDesktopItems + makeWrapper + strip-nondeterminism + zip + ]; + + desktopItems = [ + (makeDesktopItem { + name = pname; + exec = pname; + icon = pname; + comment = "A real-time strategy game made with LÖVE based on the original Stronghold by Firefly studios"; + desktopName = "Stone Kingdoms"; + genericName = pname; + categories = [ "Game" ]; + }) + ]; + + installPhase = '' + runHook preInstall + zip -9 -r stone-kingdoms.love ./* + strip-nondeterminism --type zip stone-kingdoms.love + install -Dm755 -t $out/share/games/lovegames/ stone-kingdoms.love + install -Dm644 assets/other/icon.png $out/share/icons/hicolor/256x256/apps/stone-kingdoms.png + makeWrapper ${love}/bin/love $out/bin/stone-kingdoms \ + --add-flags $out/share/games/lovegames/stone-kingdoms.love + runHook postInstall + ''; + + meta = with lib; { + description = "A real-time strategy game made with LÖVE based on the original Stronghold by Firefly studios"; + homepage = "https://gitlab.com/stone-kingdoms/stone-kingdoms"; + platforms = platforms.linux; + license = with licenses; [ + asl20 # engine + unfree # game assets + ]; + maintainers = with maintainers; [ hulr ]; + }; +} diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index c92539fe065c..523be31c5a0b 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -37755,6 +37755,8 @@ with pkgs; stepmania = callPackage ../games/stepmania { }; + stone-kingdoms = callPackage ../games/stone-kingdoms { }; + streamlit = python3Packages.callPackage ../applications/science/machine-learning/streamlit { }; stt = callPackage ../tools/audio/stt { };