2017-01-12 17:51:29 +00:00
|
|
|
{ stdenv, fetchurl, makeWrapper, jre, gnugrep, coreutils }:
|
2014-05-05 07:14:57 +01:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
2017-01-12 17:51:29 +00:00
|
|
|
name = "scala-2.10.6";
|
2014-05-05 07:14:57 +01:00
|
|
|
|
|
|
|
src = fetchurl {
|
|
|
|
url = "http://www.scala-lang.org/files/archive/${name}.tgz";
|
2017-01-12 17:51:29 +00:00
|
|
|
sha256 = "0rrdrndnxy8m76gppqh7yr68qfx0kxns5bwc69k4swz6va1zbbal";
|
2014-05-05 07:14:57 +01:00
|
|
|
};
|
|
|
|
|
2015-11-30 14:17:01 +00:00
|
|
|
propagatedBuildInputs = [ jre ] ;
|
|
|
|
buildInputs = [ makeWrapper ] ;
|
2014-05-05 07:14:57 +01:00
|
|
|
|
|
|
|
installPhase = ''
|
|
|
|
mkdir -p $out
|
|
|
|
rm bin/*.bat
|
|
|
|
mv * $out
|
|
|
|
|
|
|
|
for p in $(ls $out/bin/) ; do
|
2017-01-12 17:51:29 +00:00
|
|
|
wrapProgram $out/bin/$p \
|
|
|
|
--prefix PATH ":" ${coreutils}/bin \
|
|
|
|
--prefix PATH ":" ${gnugrep}/bin \
|
|
|
|
--prefix PATH ":" ${jre}/bin \
|
|
|
|
--set JAVA_HOME ${jre}
|
2014-05-05 07:14:57 +01:00
|
|
|
done
|
|
|
|
'';
|
|
|
|
|
|
|
|
meta = {
|
2015-04-30 16:05:14 +01:00
|
|
|
description = "A general purpose programming language";
|
2014-05-05 07:14:57 +01:00
|
|
|
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/;
|
2014-11-19 18:54:24 +00:00
|
|
|
license = stdenv.lib.licenses.bsd3;
|
2014-05-05 07:14:57 +01:00
|
|
|
platforms = stdenv.lib.platforms.all;
|
2014-11-19 18:53:56 +00:00
|
|
|
branch = "2.10";
|
2014-05-05 07:14:57 +01:00
|
|
|
};
|
|
|
|
}
|