1

I'm trying to create an Eclipse (3.x) RCP application from plugins in such a way as to allow me to provide ordinary plugins for existing Eclipse installations, but also create an RCP application from those plugins.

My experimentation has led me to have the following layout:

  • com.company.testapp.plugin
  • com.company.testapp.feature
  • com.company.testapp.updatesite

Where each ID depends on the previous one. This works correctly and I can build an update site from the plugin via the feature. What I would now like to do is add something like

  • com.company.testapp.rcp

Containing just the required machinery to provide an RCP 'wrapper' around the feature. com.company.testapp.rcp contains a product definition, testapp.product.

However, I can't seem to make this link work; I'm getting "Product com.company.testapp.rcp.product could not be found" on trying to launch from the product configuration.

(Ultimately, I'd like to be able to drive the creation of both the update site and RCP application from Maven/Tycho—I have another com.company.testapp.master containing the master POM which I can again successfully build the update site from.)

I've found plenty of resources on building plugins with Tycho, and plenty on building RCP applications, but nothing on building both from the same source tree. I'm not an Eclipse or Tycho expert by any means, so it's possible I'm just not aware of what I should be searching for.

Is such a thing even possible?

4

1 回答 1

3

Instead of com.company.testapp.updatesite (and com.company.testapp.rcp) create a new module: com.company.testapp.repository that defines a product and p2 repository (a replacement for old update-site mechanism). The module should have the following files:

  • category.xml where you define features in p2 repository and their categories (in your case com.company.testapp.feature)
  • *.product - a product definition file
  • pom.xml file that defines eclipse-repository module; detailed configuration is explained at Tycho Packaging Types - eclipse-repository
于 2012-08-09T12:22:11.043 回答