Merge pull request #83285 from hax404/teeworlds

teeworlds: python2 -> python3; add menu item
This commit is contained in:
Florian Klink 2020-03-29 20:30:58 +02:00 committed by GitHub
commit 5f0ba381ae
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,5 +1,5 @@
{ fetchFromGitHub, stdenv, cmake, pkgconfig, python, alsaLib { fetchFromGitHub, stdenv, cmake, pkgconfig, python3, alsaLib
, libX11, libGLU, SDL2, lua5_3, zlib, freetype, wavpack , libX11, libGLU, SDL2, lua5_3, zlib, freetype, wavpack, icoutils
}: }:
stdenv.mkDerivation rec { stdenv.mkDerivation rec {
@ -21,12 +21,21 @@ stdenv.mkDerivation rec {
'#define DATA_DIR "${placeholder "out"}/share/teeworlds/data"' '#define DATA_DIR "${placeholder "out"}/share/teeworlds/data"'
''; '';
nativeBuildInputs = [ cmake pkgconfig ]; nativeBuildInputs = [ cmake pkgconfig icoutils ];
buildInputs = [ buildInputs = [
python alsaLib libX11 libGLU SDL2 lua5_3 zlib freetype wavpack python3 alsaLib libX11 libGLU SDL2 lua5_3 zlib freetype wavpack
]; ];
postInstall = ''
# Convert and install desktop icon
mkdir -p $out/share/pixmaps
icotool --extract --index 1 --output $out/share/pixmaps/teeworlds.png $src/other/icons/teeworlds.ico
# Install menu item
install -D $src/other/teeworlds.desktop $out/share/applications/teeworlds.desktop
'';
meta = { meta = {
description = "Retro multiplayer shooter game"; description = "Retro multiplayer shooter game";