On Tue, 2013-10-01 at 06:48 +0200, Christopher BROWN wrote: > Hi, > > More of an Ant user, I tried configuring the POM file after downloading > http "core" (haven't tried "client" yet) to compile to Java 1.6, for a more > recent classfile format (it's slightly more efficient). > > I tried to follow advice here: > http://maven.apache.org/plugins/maven-compiler-plugin/examples/set-compiler-source-and-target.html > > ...but couldn't see any references to maven-compiler-plugin in any of the > pom.xml files (including those in subdirectories). > > There seems to be some magic going on, as I tried compiling anyway, and > after inspecting the generated classes in the generated jars ("mvn install" > was successful), it appears that the output classfile version is 49 (as in > Java 5)... I checked as follows: > javap -v org.apache.http.util.VersionInfo > > I said "magic", because I'm using Mac OS X 10.8 from 2012 with only Java 6, > 7, and 8 installed... > > I'm curious to know how Java 5 is specified and used for compilation, and > would like to compile with the most recent "javac" version possible. > > Thanks, > Christopher
The usual delights of dealing with complex build systems. I think the default compiler target and source levels are defined in the parent POM: http://search.maven.org/remotecontent?filepath=org/apache/httpcomponents/project/7/project-7.pom One should be able to override them at individual POM level, though. Oleg --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
