2012-01-18 21:32:20 +01:00
|
|
|
{ stdenv, fetchurl, makeWrapper, jre }:
|
2010-07-28 13:55:54 +02:00
|
|
|
|
2014-04-22 19:00:09 +02:00
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
name = "jruby-${version}";
|
|
|
|
|
2016-02-12 00:31:41 +01:00
|
|
|
version = "9.0.5.0";
|
2009-06-26 18:52:58 +02:00
|
|
|
|
|
|
|
src = fetchurl {
|
2016-02-12 00:31:41 +01:00
|
|
|
url = "https://s3.amazonaws.com/jruby.org/downloads/${version}/jruby-bin-${version}.tar.gz";
|
|
|
|
sha256 = "1wysymqzc7591743f2ycgwpm232y6i050izn72lck44nhnyr5wwy";
|
2009-06-26 18:52:58 +02:00
|
|
|
};
|
|
|
|
|
2012-01-18 21:32:20 +01:00
|
|
|
buildInputs = [ makeWrapper ];
|
|
|
|
|
|
|
|
installPhase = ''
|
2016-02-12 00:31:41 +01:00
|
|
|
mkdir -pv $out/docs
|
2012-01-18 21:32:20 +01:00
|
|
|
mv * $out
|
|
|
|
rm $out/bin/*.{bat,dll,exe,sh}
|
2014-04-22 19:00:09 +02:00
|
|
|
mv $out/COPYING $out/LICENSE* $out/docs
|
2012-01-18 21:32:20 +01:00
|
|
|
|
|
|
|
for i in $out/bin/*; do
|
|
|
|
wrapProgram $i \
|
|
|
|
--set JAVA_HOME ${jre}
|
|
|
|
done
|
|
|
|
'';
|
2009-06-26 18:52:58 +02:00
|
|
|
|
2014-04-22 19:00:09 +02:00
|
|
|
meta = {
|
2010-07-28 13:55:54 +02:00
|
|
|
description = "Ruby interpreter written in Java";
|
2012-01-18 21:32:20 +01:00
|
|
|
homepage = http://jruby.org/;
|
2014-11-06 01:44:33 +01:00
|
|
|
license = with stdenv.lib.licenses; [ cpl10 gpl2 lgpl21 ];
|
2016-08-02 19:50:55 +02:00
|
|
|
platforms = stdenv.lib.platforms.unix;
|
2009-06-26 18:52:58 +02:00
|
|
|
};
|
|
|
|
}
|