git.iko.soy/typeable/nixpkgs
on master help sign in
koboredux,koboredux-free: init at 0.7.5.1
commit130ce6de1c1bc39e5910be4e32e647ee7399b0f1 authorFrancesco Gazzetta <fgaz@fgaz.me> dateTue 14 Apr 2020, 10:31 (7 years ago) parent07f8e16
2 files changed+93
pkgs/games/koboredux/default.nix+87 pkgs/top-level/all-packages.nix+6
pkgs/games/koboredux/default.nixnew file+87
@@ -0,0 +1,87 @@
1+{ stdenv
2+, fetchFromGitHub
3+, fetchpatch
4+, requireFile
5+, cmake
6+, pkg-config
7+, SDL2
8+, SDL2_image
9+, audiality2
10+, useProprietaryAssets ? true
11+}:
12+
13+with stdenv.lib;
14+stdenv.mkDerivation rec {
15+ pname = "koboredux";
16+ version = "0.7.5.1";
17+
18+ src =
19+ [(fetchFromGitHub {
20+ owner = "olofson";
21+ repo = "koboredux";
22+ rev = "v${version}";
23+ sha256 = "09h9r65z8bar2z89s09j6px0gdq355kjf38rmd85xb2aqwnm6xig";
24+ })]
25+ ++
26+ (optional useProprietaryAssets (requireFile {
27+ name = "koboredux-${version}-Linux.tar.bz2";
28+ sha256 = "11bmicx9i11m4c3dp19jsql0zy4rjf5a28x4hd2wl8h3bf8cdgav";
29+ message = ''
30+ Please purchase the game on https://olofson.itch.io/kobo-redux
31+ and download the Linux build.
32+
33+ Once you have downloaded the file, please use the following command
34+ and re-run the installation:
35+
36+ nix-prefetch-url file://\$PWD/koboredux-${version}-Linux.tar.bz2
37+
38+ Alternatively, install the "koboredux-free" package, which replaces the
39+ proprietary assets with a placeholder theme.
40+ '';
41+ }));
42+
43+ sourceRoot = "source"; # needed when we have the assets source
44+
45+ # Fix clang build
46+ patches = [(fetchpatch {
47+ url = "https://github.com/olofson/koboredux/commit/cf92b8a61d002ccaa9fbcda7a96dab08a681dee4.patch";
48+ sha256 = "0dwhvis7ghf3mgzjd2rwn8hk3ndlgfwwcqaq581yc5rwd73v6vw4";
49+ })];
50+
51+ postPatch = optionalString useProprietaryAssets ''
52+ cp -r ../koboredux-${version}-Linux/sfx/redux data/sfx/
53+ cp -r ../koboredux-${version}-Linux/gfx/redux data/gfx/
54+ cp -r ../koboredux-${version}-Linux/gfx/redux_fullscreen data/gfx/
55+ '';
56+
57+ nativeBuildInputs = [
58+ cmake
59+ pkg-config
60+ ];
61+
62+ buildInputs = [
63+ SDL2
64+ SDL2_image
65+ audiality2
66+ ];
67+
68+ meta = {
69+ description = "A frantic 80's style 2D shooter, similar to XKobo and Kobo Deluxe" +
70+ optionalString (!useProprietaryAssets) " (built without proprietary assets)";
71+ longDescription = ''
72+ Kobo Redux is a frantic 80's style 2D shooter, inspired by the look and
73+ feel of 90's arcade cabinets. The gameplay is fast and unforgiving,
74+ although with less of the frustrating quirkiness of the actual games
75+ of the 80's. A true challenge in the spirit of the arcade era!
76+ '' + optionalString (!useProprietaryAssets) ''
77+
78+ This version replaces the official proprietary assets with placeholders.
79+ For the full experience, consider installing "koboredux" instead.
80+ '';
81+ homepage = "https://olofson.itch.io/kobo-redux";
82+ license = with licenses; if useProprietaryAssets then unfree else gpl2;
83+ platforms = platforms.all;
84+ maintainers = with maintainers; [ fgaz ];
85+ };
86+}
87+
pkgs/top-level/all-packages.nix+6
@@ -24246,6 +24246,12 @@ in
2424624246
2424724247 kobodeluxe = callPackage ../games/kobodeluxe { };
2424824248
24249+ koboredux = callPackage ../games/koboredux { };
24250+
24251+ koboredux-free = callPackage ../games/koboredux {
24252+ useProprietaryAssets = false;
24253+ };
24254+
2424924255 leela-zero = libsForQt5.callPackage ../games/leela-zero { };
2425024256
2425124257 lgogdownloader = callPackage ../games/lgogdownloader { };