Wednesday, July 1, 2015

Specifying javac debug flags in Maven

If you have the disgrace of using Maven in your project, you might be also unhappy about the fact that javac compilation is done using the standard debug flags

-g:{keyword list}

source Source file debugging information
lines Line number debugging information
vars Local variable debugging information

so passing -g:{source,lines,vars} activates the MAXIMUM debug info in the compiled classes.

Hew to pass these flags using maven is explained here , i.e. just add to your pom.xml this splendid XML and try not to puke for XML indigestion:


No comments: