about summary refs log tree commit diff
path: root/nixpkgs/pkgs/games/galaxis/default.nix
blob: 19df8db78a0a1c4e73ea6cc943374544b838046b (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
{ stdenv, fetchurl, ncurses, xmlto }:

with stdenv.lib;
stdenv.mkDerivation rec {

  pname = "galaxis";
  version = "1.10";

  src = fetchurl{
    url = "http://www.catb.org/~esr/galaxis/${pname}-${version}.tar.gz";
    sha256 = "1181x3z4r0794v2bkpigb5fablw1nayj42wvhy2am79p7j1iqq5r";
  };

  buildInputs = [ ncurses xmlto ];

  patchPhase = ''
    sed -i\
     -e 's|^install: galaxis\.6 uninstall|install: galaxis.6|'\
     -e 's|usr/||g' -e 's|ROOT|DESTDIR|g'\
     -e 's|install -m 755 -o 0 -g 0|install -m 755|' Makefile
  '';

  dontConfigure = true;

  makeFlags = [ "DESTDIR=$(out)" ];

  meta = {
    description = "Rescue lifeboats lost in interstellar space";
    longDescription = ''
      Lifeboats from a crippled interstellar liner are adrift in a starfield. To
      find them, you can place probes that look in all eight compass directions
      and tell you how many lifeboats they see. If you drop a probe directly on
      a lifeboat it will be revealed immediately. Your objective: find the
      lifeboats as quickly as possible, before the stranded passengers run out
      of oxygen!

      This is a UNIX-hosted, curses-based clone of the nifty little Macintosh
      freeware game Galaxis. It doesn't have the super-simple, point-and-click
      interface of the original, but compensates by automating away some of the
      game's simpler deductions.
    '';
    homepage = "http://catb.org/~esr/galaxis/";
    license = licenses.gpl2;
    maintainers = [ maintainers.AndersonTorres ];
    platforms = platforms.linux;
  };
}