diff options
author | Michiel Leenaars <ml.software@leenaa.rs> | 2016-02-27 14:20:12 +0100 |
---|---|---|
committer | Michiel Leenaars <ml.software@leenaa.rs> | 2016-02-27 22:01:53 +0100 |
commit | 41d00c436dd914a2d7f62bdffd5270b28331312d (patch) | |
tree | fdd23e3e5d188e6f43300d6e37f02597ddcf927e /pkgs/games/sienna | |
parent | 04422bb3ca8f1c09ac45817f6926199f9bfbf84f (diff) |
sienna: init at 1.0c
Diffstat (limited to 'pkgs/games/sienna')
-rw-r--r-- | pkgs/games/sienna/default.nix | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/pkgs/games/sienna/default.nix b/pkgs/games/sienna/default.nix new file mode 100644 index 0000000000000..2636bc9e79901 --- /dev/null +++ b/pkgs/games/sienna/default.nix @@ -0,0 +1,59 @@ +{ stdenv, fetchurl, unzip, love, lua, makeWrapper, makeDesktopItem }: + +let + pname = "sienna"; + version = "1.0c"; + + icon = fetchurl { + url = "http://tangramgames.dk/img/thumb/sienna.png"; + sha256 = "12q2rhk39dmb6ir50zafn8dylaad5gns8z3y21mfjabc5l5g02nn"; + }; + + desktopItem = makeDesktopItem { + name = "sienna"; + exec = "${pname}"; + icon = "${icon}"; + comment = "Fast-paced one button platformer"; + desktopName = "Sienna"; + genericName = "sienna"; + categories = "Game;"; + }; + +in + +stdenv.mkDerivation rec { + name = "${pname}-${version}"; + + src = fetchurl { + url = "https://github.com/SimonLarsen/${pname}/releases/download/v${version}/${pname}-${version}.love"; + sha256 = "1x15276fhqspgrrv8fzkp032i2qa8piywc0yy061x59mxhdndzj6"; + }; + + nativeBuildInputs = [ makeWrapper ]; + buildInputs = [ lua love ]; + + phases = "installPhase"; + + installPhase = + '' + mkdir -p $out/bin + mkdir -p $out/share/games/lovegames + + cp -v $src $out/share/games/lovegames/${pname}.love + + makeWrapper ${love}/bin/love $out/bin/${pname} --add-flags $out/share/games/lovegames/${pname}.love + + chmod +x $out/bin/${pname} + mkdir -p $out/share/applications + ln -s ${desktopItem}/share/applications/* $out/share/applications/ + ''; + + meta = with stdenv.lib; { + description = "Fast-paced one button platformer"; + maintainers = with maintainers; [ leenaars ]; + platforms = platforms.linux; + license = licenses.free; + downloadPage = http://tangramgames.dk/games/sienna; + }; + +} |