1 { lib, stdenv, fetchurl, makeDesktopItem, copyDesktopItems, SDL, SDL_mixer, freepats }:
3 stdenv.mkDerivation rec {
8 url = "http://abuse.zoy.org/raw-attachment/wiki/download/${pname}-${version}.tar.gz";
9 sha256 = "0104db5fd2695c9518583783f7aaa7e5c0355e27c5a803840a05aef97f9d3488";
14 "--with-assetdir=$(out)/orig"
15 # The "--enable-debug" is to work around a segfault on start, see https://bugs.archlinux.org/task/52915.
19 desktopItems = [ (makeDesktopItem {
23 desktopName = "Abuse";
24 comment = "Side-scroller action game that pits you against ruthless alien killers";
25 categories = [ "Game" "ActionGame" ];
30 echo -e "dir ${freepats}\nsource ${freepats}/freepats.cfg" > $out/etc/timidity.cfg
32 mv $out/bin/abuse $out/bin/.abuse-bin
33 substituteAll "${./abuse.sh}" $out/bin/abuse
34 chmod +x $out/bin/abuse
36 install -Dm644 doc/abuse.png $out/share/pixmaps/abuse.png
39 nativeBuildInputs = [ copyDesktopItems ];
40 buildInputs = [ SDL SDL_mixer freepats ];
43 description = "Side-scroller action game that pits you against ruthless alien killers";
44 homepage = "http://abuse.zoy.org/";
45 license = with licenses; [ unfree ];
46 # Most of abuse is free (public domain, GPL2+, WTFPL), however the creator
47 # of its sfx and music only gave Debian permission to redistribute the
48 # files. Our friends from Debian thought about it some more:
49 # https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=648272
50 maintainers = with maintainers; [ iblech ];
51 platforms = platforms.unix;
52 broken = stdenv.isDarwin;