eigenmath: 3.33-unstable-2024-11-22 -> 3.35-unstable-2024-12-11 (#364381)
[NixPkgs.git] / pkgs / games / openra_2019 / engines.nix
blob3bbce300cfa534597e3096b6ab786be3a5808b86
2   buildOpenRAEngine,
3   fetchFromGitHub,
4   postFetch,
5 }:
7 let
8   buildUpstreamOpenRAEngine =
9     {
10       version,
11       rev,
12       sha256,
13     }:
14     name:
15     (buildOpenRAEngine {
16       inherit version;
17       description = "Open-source re-implementation of Westwood Studios' 2D Command and Conquer games";
18       homepage = "https://www.openra.net/";
19       mods = [
20         "cnc"
21         "d2k"
22         "ra"
23         "ts"
24       ];
25       src = fetchFromGitHub {
26         owner = "OpenRA";
27         repo = "OpenRA";
28         inherit rev sha256 postFetch;
29       };
30     } name).overrideAttrs
31       (origAttrs: {
32         postInstall = ''
33           ${origAttrs.postInstall}
34           cp -r mods/ts $out/lib/openra/mods/
35           cp mods/ts/icon.png $(mkdirp $out/share/pixmaps)/openra-ts.png
36           ( cd $out/share/applications; sed -e 's/Dawn/Sun/g' -e 's/cnc/ts/g' openra-cnc.desktop > openra-ts.desktop )
37         '';
38       });
42   release =
43     name:
44     (buildUpstreamOpenRAEngine rec {
45       version = "20190314";
46       rev = "${name}-${version}";
47       sha256 = "15pvn5cx3g0nzbrgpsfz8dngad5wkzp5dz25ydzn8bmxafiijvcr";
48     } name);
50   playtest =
51     name:
52     (buildUpstreamOpenRAEngine rec {
53       version = "20190302";
54       rev = "${name}-${version}";
55       sha256 = "1vqvfk2p2lpk3m0d3rpvj34i8cmk3mfc7w4cn4llqd9zp4kk9pya";
56     } name);
58   bleed = buildUpstreamOpenRAEngine {
59     version = "8ee1102";
60     rev = "8ee11028d72cde7556b31d45f556b40be65b4b70";
61     sha256 = "0f1fpf37ms8d7fhlh3rjzsxsk9w23iyi3phs2i7g561292d5rk3l";
62   };