nixpkgs-suyu/pkgs/development/compilers/ecj/builder.sh
Martin Bravenboer 7e75cb7cc4 Added ecj (The Eclipse Compiler for Java) to Nix. This means that Java
5.0 code can now be compiled and run in Nix (the J2RE 5.0 was already
available without deployment problems).

Also, I need ecj to checkout its behaviour and warnings as a second
reference (javac).


svn path=/nixpkgs/trunk/; revision=3783
2005-09-06 00:00:22 +00:00

21 lines
349 B
Bash

. $stdenv/setup
unzip $src
cd jdtcoresrc
ant -f compilejdtcorewithjavac.xml
mkdir -p $out/share/ecj
mv ecj.jar $out/share/ecj
mkdir -p $out/bin
cat >> $out/bin/ecj <<EOF
#! /bin/sh
export JAVA_HOME=$j2re
export LANG="en_US"
$j2re/bin/java -cp $out/share/ecj/ecj.jar org.eclipse.jdt.internal.compiler.batch.Main \$@
EOF
chmod u+x $out/bin/ecj