Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 419809

Summary: Unable to resolve Eclipse license feature in build
Product: Community Reporter: Benjamin Schmeling <Benjamin.Schmeling>
Component: CI-JenkinsAssignee: CI Admin Inbox <ci.admin-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: david_williams, thanh.ha, webmaster
Version: unspecified   
Target Milestone: ---   
Hardware: Macintosh   
OS: Mac OS X   
Whiteboard:

Description Benjamin Schmeling CLA 2013-10-18 03:56:04 EDT
I configured my build https://hudson.eclipse.org/hudson/job/org.eclipse.fmc-nightlybuild/16/console to install an Eclipse feature with Tycho. My feature.xml defines the license-feature="org.eclipse.license". However, Maven tries to resolve the matching artifact and throws the following exception:

org.apache.maven.InternalErrorException: Internal error: java.lang.RuntimeException: "No solution found because the problem is unsatisfiable.": ["Unable to satisfy dependency from org.eclipse.fmc.feature.feature.group 0.11.0.qualifier to org.eclipse.license.feature.group 0.0.0.", "No solution found because the problem is unsatisfiable."]

Is there a standard way to solve this problem for Eclipse plugins? Alternatively I could build my own license feature as described here: https://eclipse.googlesource.com/e4/org.eclipse.e4.ui/+/1ef7e5bbe593ddce032eb62a15b484aa89055c52/examples/tycho/license-feature-example/org.eclipse.license. However, shouldn't there be already such a feature  available in the p2 repositories http://download.eclipse.org/releases/luna or http://download.eclipse.org/releases/kepler ?
Comment 1 Benjamin Schmeling CLA 2013-10-18 03:57:31 EDT
Or could someone point me to an example project on the Eclipse Hudson which is also using Maven/Tycho for the build?
Comment 2 David Williams CLA 2013-10-18 07:10:44 EDT
Thanh, did you ever provide a "CBI Document" for this? 

In the Eclipse Platform, we configure "dependency URL" to point to the (new) CBI provided license In parent pom 

As a global property, we define

    
    <!-- CBI provided common license feature. (bug 394793) -->
    <license-repo.url>http://download.eclipse.org/cbi/updates/license/</license-repo.url>
    

Then in 'repositories'

 <repositories>
      <repository>
      <id>license-feature</id>
      <url>${license-repo.url}</url>
      <layout>p2</layout>
    </repository>
    .
    .
    .
 </repositories>

Then in any particular feature, use the standard

<?xml version="1.0" encoding="UTF-8"?>
<feature
      id="org.eclipse.help"
      label="%featureName"
      version="2.0.0.qualifier"
      provider-name="%providerName"
      plugin="org.eclipse.help.base"
      license-feature="org.eclipse.license"
      license-feature-version="1.0.0.qualifier"> 
....


Hope this helps.
Comment 3 Benjamin Schmeling CLA 2013-10-18 07:23:17 EDT
Works perfectly! Thanks a lot. I did not find any information about the cbi repos to solve this issue (and I googled a lot). There should be an official document for this.
Comment 4 Thanh Ha CLA 2013-10-18 09:28:30 EDT
(In reply to Benjamin Schmeling from comment #3)
> Works perfectly! Thanks a lot. I did not find any information about the cbi
> repos to solve this issue (and I googled a lot). There should be an official
> document for this.

There should be and I have plans to create one but I'm stuck waiting on bug 400250 before I can ask for a web space to host the new CBI documention I've been working on.

I will add some information to the CBI wiki page to mention the license in the meantime though [1].


[1] http://wiki.eclipse.org/CBI