diff options
author | Karn Kallio <kkallio@skami.org> | 2013-11-09 17:14:05 -0430 |
---|---|---|
committer | Peter Simons <simons@cryp.to> | 2013-11-11 12:11:00 +0100 |
commit | 1e80c57274b7e2877ac554b5a51f868253fafdc1 (patch) | |
tree | 9c8df21ec5440f7e2bdf7fa3d86a902c752d963a /pkgs/development/compilers/scala | |
parent | 6441a9c1d08a0c309f7a85980b9ad86f2d84ecd5 (diff) |
scala: add expression for scala 2.10.x branch.
Diffstat (limited to 'pkgs/development/compilers/scala')
-rw-r--r-- | pkgs/development/compilers/scala/2.9.nix | 34 | ||||
-rw-r--r-- | pkgs/development/compilers/scala/default.nix | 17 |
2 files changed, 44 insertions, 7 deletions
diff --git a/pkgs/development/compilers/scala/2.9.nix b/pkgs/development/compilers/scala/2.9.nix new file mode 100644 index 0000000000000..a7c9dbc907361 --- /dev/null +++ b/pkgs/development/compilers/scala/2.9.nix @@ -0,0 +1,34 @@ +{ stdenv, fetchurl }: + +# at runtime, need jre or jdk + +stdenv.mkDerivation rec { + name = "scala-2.9.2"; + + src = fetchurl { + url = "http://www.scala-lang.org/downloads/distrib/files/${name}.tgz"; + sha256 = "0s1shpzw2hyz7bwxdqq19rcrzbpq4d7b0kvdvjvhy7h05x496b46"; + }; + + installPhase = '' + mkdir -p $out + rm bin/*.bat + rm lib/scalacheck.jar + mv * $out + ''; + + meta = { + description = "Scala is a general purpose programming language"; + longDescription = '' + Scala is a general purpose programming language designed to express + common programming patterns in a concise, elegant, and type-safe way. + It smoothly integrates features of object-oriented and functional + languages, enabling Java and other programmers to be more productive. + Code sizes are typically reduced by a factor of two to three when + compared to an equivalent Java application. + ''; + homepage = http://www.scala-lang.org/; + license = "BSD"; + platforms = stdenv.lib.platforms.all; + }; +} diff --git a/pkgs/development/compilers/scala/default.nix b/pkgs/development/compilers/scala/default.nix index a7c9dbc907361..c128baf5100fd 100644 --- a/pkgs/development/compilers/scala/default.nix +++ b/pkgs/development/compilers/scala/default.nix @@ -1,20 +1,23 @@ -{ stdenv, fetchurl }: - -# at runtime, need jre or jdk +{ stdenv, fetchurl, makeWrapper, jre }: stdenv.mkDerivation rec { - name = "scala-2.9.2"; + name = "scala-2.10.3"; src = fetchurl { - url = "http://www.scala-lang.org/downloads/distrib/files/${name}.tgz"; - sha256 = "0s1shpzw2hyz7bwxdqq19rcrzbpq4d7b0kvdvjvhy7h05x496b46"; + url = "http://www.scala-lang.org/files/archive/${name}.tgz"; + sha256 = "16ac935wydrxrvijv4ldnz4vl2xk8yb3yzb9bsi3nb9sic7fxl95"; }; + buildInputs = [ jre makeWrapper ] ; + installPhase = '' mkdir -p $out rm bin/*.bat - rm lib/scalacheck.jar mv * $out + + for p in $(ls $out/bin/) ; do + wrapProgram $out/bin/$p --prefix PATH ":" ${jre}/bin ; + done ''; meta = { |