···11+{ stdenv, fetchurl, ncurses, xmlto }:
22+33+with stdenv.lib;
44+stdenv.mkDerivation rec{
55+66+ name = "galaxis-${version}";
77+ version = "1.9";
88+99+ src = fetchurl{
1010+ url = "http://www.catb.org/~esr/galaxis/${name}.tar.gz";
1111+ sha256 = "1dsypk5brfbc399pg4fk9myyh5yyln0ljl1aiqkypws8h4nsdphl";
1212+ };
1313+1414+ buildInputs = [ ncurses xmlto ];
1515+1616+ patchPhase = ''
1717+ sed -i\
1818+ -e 's|^install: galaxis\.6 uninstall|install: galaxis.6|'\
1919+ -e 's|usr/||g' -e 's|ROOT|DESTDIR|g'\
2020+ -e 's|install -m 755 -o 0 -g 0|install -m 755|' Makefile
2121+ '';
2222+2323+ dontConfigure = true;
2424+2525+ makeFlags = [ "DESTDIR=$(out)" ];
2626+2727+ meta = {
2828+ description = "Rescue lifeboats lost in interstellar space";
2929+ longDescription = ''
3030+ Lifeboats from a crippled interstellar liner are adrift in a starfield. To
3131+ find them, you can place probes that look in all eight compass directions
3232+ and tell you how many lifeboats they see. If you drop a probe directly on
3333+ a lifeboat it will be revealed immediately. Your objective: find the
3434+ lifeboats as quickly as possible, before the stranded passengers run out
3535+ of oxygen!
3636+3737+ This is a UNIX-hosted, curses-based clone of the nifty little Macintosh
3838+ freeware game Galaxis. It doesn't have the super-simple, point-and-click
3939+ interface of the original, but compensates by automating away some of the
4040+ game's simpler deductions.
4141+ '';
4242+ homepage = http://catb.org/~esr/galaxis/;
4343+ license = licenses.gpl2;
4444+ maintainers = [ maintainers.AndersonTorres ];
4545+ platforms = platforms.linux;
4646+ };
4747+}