summary refs log tree commit diff
path: root/pkgs/development/compilers/nim/default.nix
blob: a4dbfeac8342ab6150896f0c417f5e37e3720e12 (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
{ stdenv, fetchurl, unzip }:

stdenv.mkDerivation rec {
  name = "nim-0.13.0";

  src = fetchurl {
    url = "http://nim-lang.org/download/${name}.tar.xz";
    sha256 = "1adiij20n1cigsc44dbp60jdbydmkfp7ixbddmcn6h4dfvjzaqfd";
  };

  buildPhase   = "sh build.sh";
  installPhase =
    ''
      installBin bin/nim
      substituteInPlace install.sh --replace '$1/nim' "$out"
      sh install.sh $out
    '';

  meta = with stdenv.lib;
    { description = "Statically typed, imperative programming language";
      homepage = http://nim-lang.org/;
      license = licenses.mit;
      maintainers = with maintainers; [ ehmry ];
      platforms = platforms.linux ++ platforms.darwin; # arbitrary
    };
}