blob: 3680f3af1275c55a5c666943be1782ff058691f5 (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
{ lib
, stdenvNoCC
, fetchFromGitLab
, copyDesktopItems
, love
, makeDesktopItem
, makeWrapper
, strip-nondeterminism
, zip
}:
stdenvNoCC.mkDerivation rec {
pname = "stone-kingdoms";
version = "0.6.1";
src = fetchFromGitLab {
owner = "stone-kingdoms";
repo = pname;
rev = version;
hash = "sha256-W2hzJg22O857Kh7CJVVHV5qu8QKjXCwW3hmgKBc0n2g=";
};
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 ];
};
}
|