Building pure e4 application with maven/tycho [message #1794751] |
Thu, 06 September 2018 05:33 |
|
I am building a small e4 application and everything is coming along nicely. You can see the code here [1]. When I tried to add keyboard shortcuts for menu items, I stumbled over this [2] and realized, that in addition to the 4.x workbench plugins, somehow also the 3.x style workbench plugins (org.eclipse.ui.workbench, ...) were added to the target platform (and the final product).
When I manually removed these plugins after the deployment from the plugins folder of the final product, the keyboard shortcuts were working and shown right next to the menu items.
My next goal was to get rid of these 3.x workbench plugins in the target platform. In the Eclipse launcher, I was able to get rid of the 3.x workbench plugins simply by deselecting these plugins from the list of enabled plugins. The application launched just fine - and the shortcuts were there.
Finally, I wanted to do the same thing with my maven/tycho build. At first, I tried to manually remove the plugin from the target platform. Unfortunately, tycho/maven does not support that and provided me with link to "Filtering" (see [3]) in the target platform. I tried that approach by filtering the eclipse-plugin "org.eclipse.ui.workbench" (and also org.eclipse.compare):
<filters>
<filter>
<type>eclipse-plugin</type>
<id>org.eclipse.ui.workbench</id>
<removeAll />
</filter>
<filter>
<type>eclipse-plugin</type>
<id>org.eclipse.compare</id>
<removeAll />
</filter>
</filters>
Unfortunately, the dependency resolution of the build failed, because org.eclipse.platform.feature.group seems to require compare (which requires workbench):
[ERROR] Software being installed: blackant 1.0.0
[ERROR] Missing requirement: org.eclipse.platform.feature.group 4.8.0.v20180611-0656 requires 'org.eclipse.equinox.p2.iu; org.eclipse.compare [3.7.200.v20180418-1233,3.7.200.v20180418-1233]' but it could not be found
[ERROR] Cannot satisfy dependency: blackant 1.0.0 depends on: org.eclipse.equinox.p2.iu; org.eclipse.platform.feature.group [4.8.0.v20180611-0656,4.8.0.v20180611-0656]
My target platform is pretty simple:
<locations>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="http://download.eclipse.org/releases/photon"/>
<unit id="org.eclipse.equinox.sdk.feature.group" version="3.14.0.v20180518-2029"/>
<unit id="org.eclipse.sdk.feature.group" version="4.8.0.v20180611-0826"/>
<unit id="org.eclipse.xtend.sdk.feature.group" version="2.14.0.v20180523-0937"/>
</location>
<location includeAllPlatforms="false" includeConfigurePhase="true" includeMode="planner" includeSource="true" type="InstallableUnit">
<repository location="http://download.eclipse.org/tools/orbit/downloads/drops/R20180606145124/repository"/>
<unit id="org.apache.commons.io.source" version="2.2.0.v201405211200"/>
<unit id="javax.xml" version="1.3.4.v201005080400"/>
<unit id="org.apache.commons.codec" version="1.10.0.v20180409-1845"/>
<unit id="org.apache.commons.collections" version="3.2.2.v201511171945"/>
<unit id="org.apache.poi" version="3.9.0.v201405241750"/>
<unit id="org.apache.poi.ooxml" version="3.9.0.v201405241905"/>
<unit id="org.apache.poi.ooxml.schemas" version="3.9.0.v201405241750"/>
<unit id="org.apache.xmlbeans" version="2.3.0.v201605172150"/>
</location>
</locations>
I know the app works fine, when I use the eclipse builder / launcher. So in short, my question is: what feature(s) should I add to my target platform, so that I can have a maven/tycho build and no dependency to org.eclipse.ui.workbench?
[1]: https://github.com/roberthilbrich/blackant
[2]: https://www.eclipse.org/forums/index.php/t/842677/
[3]: https://wiki.eclipse.org/Tycho/Target_Platform#Filtering
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.03559 seconds