uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
88
pkgs/games/srb2kart/default.nix
Normal file
88
pkgs/games/srb2kart/default.nix
Normal file
|
|
@ -0,0 +1,88 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, fetchurl
|
||||
, fetchFromGitHub
|
||||
, substituteAll
|
||||
, cmake
|
||||
, curl
|
||||
, nasm
|
||||
, unzip
|
||||
, libgme
|
||||
, libpng
|
||||
, SDL2
|
||||
, SDL2_mixer
|
||||
, zlib
|
||||
}:
|
||||
|
||||
let
|
||||
|
||||
release_tag = "v1.3";
|
||||
|
||||
installer = fetchurl {
|
||||
url = "https://github.com/STJr/Kart-Public/releases/download/${release_tag}/srb2kart-v13-Installer.exe";
|
||||
sha256 = "0bk36y7wf6xfdg6j0b8qvk8671hagikzdp5nlfqg478zrj0qf6cs";
|
||||
};
|
||||
|
||||
in stdenv.mkDerivation rec {
|
||||
pname = "srb2kart";
|
||||
version = "1.3.0";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "STJr";
|
||||
repo = "Kart-Public";
|
||||
rev = release_tag;
|
||||
sha256 = "131g9bmc9ihvz0klsc3yzd0pnkhx3mz1vzm8y7nrrsgdz5278y49";
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
cmake
|
||||
nasm
|
||||
unzip
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
curl
|
||||
libgme
|
||||
libpng
|
||||
SDL2
|
||||
SDL2_mixer
|
||||
zlib
|
||||
];
|
||||
|
||||
cmakeFlags = [
|
||||
#"-DSRB2_ASSET_DIRECTORY=/build/source/assets"
|
||||
"-DGME_INCLUDE_DIR=${libgme}/include"
|
||||
"-DSDL2_MIXER_INCLUDE_DIR=${SDL2_mixer}/include/SDL2"
|
||||
"-DSDL2_INCLUDE_DIR=${SDL2.dev}/include/SDL2"
|
||||
];
|
||||
|
||||
patches = [
|
||||
./wadlocation.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace src/sdl/i_system.c \
|
||||
--replace '@wadlocation@' $out
|
||||
'';
|
||||
|
||||
preConfigure = ''
|
||||
mkdir assets/installer
|
||||
pushd assets/installer
|
||||
unzip ${installer} "*.kart" srb2.srb
|
||||
popd
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
mkdir -p $out/bin $out/share/games/SRB2Kart
|
||||
mv $out/srb2kart* $out/bin/
|
||||
mv $out/*.kart $out/share/games/SRB2Kart
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "SRB2Kart is a classic styled kart racer";
|
||||
homepage = "https://mb.srb2.org/threads/srb2kart.25868/";
|
||||
platforms = platforms.linux;
|
||||
license = licenses.gpl2Plus;
|
||||
maintainers = with maintainers; [ viric ];
|
||||
};
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue