git.iko.soy/typeable/nixpkgs
on master help sign in
Merge pull request #85203 from fgaz/koboredux/init

audiality2, koboredux: init

commit2f352077e7c2c8e8f4c4da42259f0bac023b096d authorTimo Kaufmann <timokau@zoho.com> dateWed 23 Sep 2020, 21:18 (6 years ago) parentec3714b130ce6d
3 files changed+134
pkgs/development/libraries/audiality2/default.nix+39 pkgs/games/koboredux/default.nix+87 pkgs/top-level/all-packages.nix+8
pkgs/development/libraries/audiality2/default.nixnew file+39
@@ -0,0 +1,39 @@
1+{ stdenv
2+, fetchFromGitHub
3+, cmake
4+, pkg-config
5+# The two audio backends:
6+, SDL2
7+, jack2
8+}:
9+
10+stdenv.mkDerivation rec {
11+ pname = "audiality2";
12+ version = "1.9.4";
13+
14+ src = fetchFromGitHub {
15+ owner = "olofson";
16+ repo = "audiality2";
17+ rev = "v${version}";
18+ sha256 = "0ipqna7a9mxqm0fl9ggwhbc7i9yxz3jfyi0w3dymjp40v7jw1n20";
19+ };
20+
21+ nativeBuildInputs = [
22+ cmake
23+ pkg-config
24+ ];
25+
26+ buildInputs = [
27+ SDL2
28+ jack2
29+ ];
30+
31+ meta = with stdenv.lib; {
32+ description = "A realtime scripted modular audio engine for video games and musical applications";
33+ homepage = "http://audiality.org";
34+ license = licenses.zlib;
35+ platforms = platforms.all;
36+ maintainers = with maintainers; [ fgaz ];
37+ };
38+}
39+
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+8
@@ -11924,6 +11924,8 @@ in
1192411924
1192511925 aubio = callPackage ../development/libraries/aubio { };
1192611926
11927+ audiality2 = callPackage ../development/libraries/audiality2 { };
11928+
1192711929 audiofile = callPackage ../development/libraries/audiofile {
1192811930 inherit (darwin.apple_sdk.frameworks) AudioUnit CoreServices;
1192911931 };
@@ -25078,6 +25080,12 @@ in
2507825080
2507925081 kobodeluxe = callPackage ../games/kobodeluxe { };
2508025082
25083+ koboredux = callPackage ../games/koboredux { };
25084+
25085+ koboredux-free = callPackage ../games/koboredux {
25086+ useProprietaryAssets = false;
25087+ };
25088+
2508125089 leela-zero = libsForQt5.callPackage ../games/leela-zero { };
2508225090
2508325091 legendary-gl = python38Packages.callPackage ../games/legendary-gl { };