Mercurial > hg > Blog
comparison content/Maven/cross-jdk-project-files-continued.md @ 0:4cd9b65e10e4
initial import of the pelican based blog
author | Dirk Olmes <dirk@xanthippe.ping.de> |
---|---|
date | Fri, 28 Jun 2013 08:48:58 +0200 |
parents | |
children | 1d9382b0329b |
comparison
equal
deleted
inserted
replaced
-1:000000000000 | 0:4cd9b65e10e4 |
---|---|
1 Title: Cross JDK project files with Maven (continued) | |
2 Date: 2008-03-21 | |
3 Lang: en | |
4 | |
5 In [my last blog entry](|filename|./cross-jdk-project-files.md) I described the steps for cross-JDK Eclipse project files. | |
6 | |
7 Unfortunately there's more Eclipse internals involved when dealing with cross platform issues. It turns out that the correct JRE_CONTAINER for Linux and Windows is | |
8 | |
9 org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/jdk | |
10 | |
11 but that doesn't work for Mac where it needs to be like this: | |
12 | |
13 org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.launching.macosx.MacOSXType/jdk | |
14 | |
15 So for real cross platform project files you need to put the launcher type into a property and override that in a mac specific profile. The final pom will look similar to this | |
16 | |
17 :::xml | |
18 <project ...> | |
19 <properties> | |
20 <vmtype>org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType</vmtype> | |
21 <jdkName>jdk1.4</jdkName> | |
22 </properties> | |
23 | |
24 <plugin> | |
25 <groupId>org.apache.maven.plugins</groupId> | |
26 <artifactId>maven-eclipse-plugin</artifactId> | |
27 <version>2.5</version> | |
28 <configuration> | |
29 <classpathContainers> | |
30 <classpathContainer> | |
31 org.eclipse.jdt.launching.JRE_CONTAINER/${vmtype}/${jdkName} | |
32 </classpathContainer> | |
33 </classpathContainers> | |
34 </configuration> | |
35 </plugin> | |
36 | |
37 <profiles> | |
38 <profile> | |
39 <id>mac</id> | |
40 <activation> | |
41 <os> | |
42 <family>mac</family> | |
43 </os> | |
44 </activation> | |
45 <properties> | |
46 <vmtype>org.eclipse.jdt.internal.launching.macosx.MacOSXType</vmtype> | |
47 </properties> | |
48 </profile> | |
49 </profiles> | |
50 </project> |