maven-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jesse Glick (JIRA)" <>
Subject [jira] (MCOMPILER-144) Using compiler API instead of tools.jar
Date Wed, 02 Apr 2014 14:50:59 GMT


Jesse Glick commented on MCOMPILER-144:

I guess so. It would still be great for the OpenJDK compiler to be published in Central somehow,
and a ?compiler plugin plugin? implementation published which uses it. Ideally this would
be coördinated somehow with the OpenJDK tools team so it is considered an official build,
though this might get into thorny TCK territory.

> Using compiler API instead of tools.jar
> ---------------------------------------
>                 Key: MCOMPILER-144
>                 URL:
>             Project: Maven Compiler Plugin
>          Issue Type: New Feature
>            Reporter: Markus KARG
>            Priority: Minor
> Currently (MVN 3.0) java compilation needs tools.jar provided by the Sun JDK:
> [ERROR] Unable to locate the Javac Compiler in:
> [ERROR] C:\Program Files\Java\jre6\..\lib\tools.jar
> [ERROR] Please ensure you are using JDK 1.4 or above and
> [ERROR] not a JRE (the class is required).
> [ERROR] In most cases you can change the location of your Java
> [ERROR] installation by setting the JAVA_HOME environment variable.
> In fact, this is bad because (a) it assumes that a full JDK is installed just for this
sole tool where a JRE would be sufficient, (b) tools.jar is not contained in any standards
documents and such possibly is not existing on future or non-sun JDK.
> Since JRE 6 (i. e. for many years) the JRE (not JDK!) comes with a standardized (!) API
for compilation: The Java Compiler API. It would make sense to use that standardized API instead
of forcing the user to have Sun JDK installed.

This message was sent by Atlassian JIRA

View raw message