2013-11-05 13:19:11 +00:00
|
|
|
{ stdenv, fetchurl, jre }:
|
2010-05-08 21:51:47 +00:00
|
|
|
|
2013-11-05 13:19:11 +00:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "sbt-${version}";
|
|
|
|
version = "0.13.0";
|
2013-05-14 22:41:22 +00:00
|
|
|
|
2013-11-05 13:19:11 +00:00
|
|
|
src = fetchurl {
|
|
|
|
url = "http://repo.typesafe.com/typesafe/ivy-releases/org.scala-sbt/sbt-launch/${version}/sbt-launch.jar";
|
|
|
|
sha256 = "04s49v5mw4kwz1rmvbf07kq51i2m0lcv60c9i5y524gjj518pk1w";
|
2013-05-14 22:41:22 +00:00
|
|
|
};
|
2010-05-08 21:51:47 +00:00
|
|
|
|
2013-11-05 13:19:11 +00:00
|
|
|
phases = [ "installPhase" ];
|
2013-05-14 22:41:22 +00:00
|
|
|
|
|
|
|
installPhase = ''
|
2013-11-05 13:19:11 +00:00
|
|
|
mkdir -p $out/bin
|
|
|
|
cat > $out/bin/sbt << EOF
|
|
|
|
#!/bin/sh
|
|
|
|
SBT_OPTS="-Xms512M -Xmx1536M -Xss1M -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=384M"
|
2013-12-08 18:49:40 +00:00
|
|
|
${jre}/bin/java \$SBT_OPTS -jar ${src} "\$@"
|
2013-05-14 22:41:22 +00:00
|
|
|
EOF
|
2013-11-05 13:19:11 +00:00
|
|
|
chmod +x $out/bin/sbt
|
2013-05-14 22:41:22 +00:00
|
|
|
'';
|
|
|
|
|
2013-11-05 13:19:11 +00:00
|
|
|
meta = {
|
|
|
|
homepage = http://www.scala-sbt.org/;
|
|
|
|
license = stdenv.lib.licenses.bsd3;
|
|
|
|
description = "A build tool for Scala, Java and more";
|
|
|
|
maintainers = [ stdenv.lib.maintainers.rickynils ];
|
|
|
|
};
|
2013-05-14 22:41:22 +00:00
|
|
|
}
|