I don't believe this has been properly addressed yet, but there are a
couple of ways to change the flags to javac that work now. Note that
these variables might change and we aren't officially declaring this as
a supported method.
JAVAC_FLAGS is added to all javac command lines. It's defined in
spec.gmk (by configure) but is currently empty and setting it on the
command line should override.
DISABLE_WARNINGS is set in jdk/makefiles/Setup.gmk and defines a long
-Xlint parameter disabling most (if not all) warnings. Overriding it
would be a first step towards enabling warnings in the jdk repo.
Both of these need to be on the command line to be overridden.
/Erik
On 2012-12-20 23:54, Dan Xu wrote:
Hi,
I wonder how I can pass javac options in the new build systemto enable
javac warnings. In the old build, I can set environment variables to
enable build warnings. For example, JAVAC_LINT_OPTIONS="-Xlint:all",
JAVAC_MAX_WARNINGS="true", and JAVAC_WARNINGS_FATAL="false". How can I
get similar warning output in the new build? Thanks!
-Dan