Igor,The problem (I think) is that /my/ '~' directory is not what hudson will search when I run the hudson job. Isn't the build run with the 'hudsonBuild' user? I've just tried to copy/paste the toolchains.xml file attached to the bug you've linked to in my own ~/.m2 directory ... but this resulted in the same failure as when I tried earlier with a custom toolchains.xml. See the console here [1] or the error message :
Failed to execute goal org.eclipse.tycho:tycho-compiler-plugin:0.14.1:compile (default-compile) on project org.eclipse.emf.compare: useJDK = BREE configured, but no toolchain of type 'jdk' with id 'J2SE-1.5' found.Did you really manage to get this working when launched from the eclipse hudson instance? If yes, could you point me to the configuration of your job so that I can check if mine [2] has the necessary options set?
Alternatively, do you know if I can set my job to be verbose on the tycho failures? I saw somewhere that tycho can report the path "where" it looked for the toolchains.xml file, but I don't know how to specify this switch to the hudson build.
Laurent[1] https://hudson.eclipse.org/hudson/view/Modeling/job/emf-compare-master/326/console
[2] https://hudson.eclipse.org/hudson/view/Modeling/job/emf-compare-master/ On 25/09/2012 13:14, Igor Fedorenko wrote:
toolchain.xml must be available on slave in ~/.m2 directory. You can find sample toolchain.xml and libraries that correspond to restricted execution environments attached to bug 386649 [1]. Beware that there is currently an outstanding issue with IBM JDKs tracked as bug 389856 [2] [1] https://bugs.eclipse.org/bugs/show_bug.cgi?id=386649 [2] https://bugs.eclipse.org/bugs/show_bug.cgi?id=389856 -- Regards, Igor On 12-09-25 7:05 AM, Laurent Goubet wrote:Hi all, One of our plugins cannot be compiled against java 1.6 and has to be compiled with the javac of jdk 1.5. In short, one of the jdk classes has changed the signature of one of its methods' generics between the two versions (see version 1.5 [1] and version 1.6 [2]). AFAIK, the incompatibility is only at source level and the compiled classes should work with both the 1.5 and 1.6 runtimes. The problem, however, is "how" can I force tycho to use the jdk 1.5 compiler when run from the Eclipse hudson instance? I read some documentation, most notablyhttp://www.eclipse.org/tycho/sitedocs/tycho-compiler-plugin/compile-mojo.htmlthat describes some potentially interesting options. "source" and "target" are not enough in my case. Telling javac that my sources are in 1.5 is not enough. "fork" seems out of the question when using tycho-compiler-plugin from version 0.14.1. My builds fail in "compileOutOfProcess is not supported" which rules out all options that require forking (compilerVersion, executable, ... and maybe others). The "useJDK" option was promising... but for the life of me I could not understand how to provide the accurate "toolchains.xml" to my builds. Should it be located in the "<home>/.m2" of the hudsonBuild user? A way seems to exist since I found this option used in one of the eclipse repositories. Seehttp://git.eclipse.org/c/cbi/platform-aggregator.git/tree/eclipse-parent/pom.xml?h=JunoSR1_RC1_R4... and the line just above the use of this option :|TODO provide CBI-specific wiki that explains how to setup BREE libraries and toolchain.xml|Yup, the wiki would have helped :). The only remaining option I could find was to use the workaround outlined by Bernd on the forum : http://www.eclipse.org/forums/index.php/t/201042/ . <pluginManagement> <plugins> <plugin> <groupId>org.eclipse.tycho</groupId> <artifactId>tycho-compiler-plugin</artifactId> <version>${tycho-version}</version> <configuration> <compilerId>jdt</compilerId> <compilerArguments><bootclasspath>/shared/common/jdk-1.5.0-22.x86_64/jre/lib/rt.jar</bootclasspath></compilerArguments> </configuration> </plugin> </pluginManagement> But that seems like a very fragile work around. Not to mention that now, my tests fail because of the tycho-surefire-plugin(https://hudson.eclipse.org/hudson/view/Modeling/job/emf-compare-master/322/console)...If anyone here has any experience with tying tycho/hudson builds to a specific jdk, any workaround as to how we can provide a toolchains.xml for our build, or simply some input as to whether this "toolchains.xml" should be provided for all jobs that would like to use it (it seems to me like using the BREE of our plugins should be the "default" way of building our plugins instead of using the jdk 6...), I'd really appreciate the help :). Laurent [1]http://docs.oracle.com/javase/1.5.0/docs/api/java/util/concurrent/ExecutorService.html#invokeAll%28java.util.Collection%29[2]http://docs.oracle.com/javase/6/docs/api/java/util/concurrent/ExecutorService.html#invokeAll%28java.util.Collection%29_______________________________________________ cross-project-issues-dev mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/cross-project-issues-dev_______________________________________________ cross-project-issues-dev mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/cross-project-issues-dev
<<attachment: laurent_goubet.vcf>>
_______________________________________________ cross-project-issues-dev mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/cross-project-issues-dev
