antlr4: add add antlr4-parse to bin

Reference: 8188dc5388/tool/src/org/antlr/v4/gui/Interpreter.java (L22)
This commit is contained in:
Nick Cao 2023-03-13 10:13:56 +08:00
parent 2cec455632
commit 9a96b203e3
No known key found for this signature in database

View File

@ -42,11 +42,15 @@ let
echo "#! ${stdenv.shell}" >> "$out/bin/antlr"
echo "'${jre}/bin/java' -cp '$out/share/java/antlr-${version}-complete.jar:$CLASSPATH' -Xmx500M org.antlr.v4.Tool \"\$@\"" >> "$out/bin/antlr"
echo "#! ${stdenv.shell}" >> "$out/bin/antlr-parse"
echo "'${jre}/bin/java' -cp '$out/share/java/antlr-${version}-complete.jar:$CLASSPATH' -Xmx500M org.antlr.v4.gui.Interpreter \"\$@\"" >> "$out/bin/antlr-parse"
echo "#! ${stdenv.shell}" >> "$out/bin/grun"
echo "'${jre}/bin/java' -cp '$out/share/java/antlr-${version}-complete.jar:$CLASSPATH' org.antlr.v4.gui.TestRig \"\$@\"" >> "$out/bin/grun"
chmod a+x "$out/bin/antlr" "$out/bin/grun"
chmod a+x "$out/bin/antlr" "$out/bin/antlr-parse" "$out/bin/grun"
ln -s "$out/bin/antlr"{,4}
ln -s "$out/bin/antlr"{,4}-parse
'';
inherit jre;