How to enable Software Update in an Eclipse product?
Asked Answered
B

3

5

In my Eclipse project, I defined a simple plugin (bundle), a feature that includes the plugin and a product that includes the feature.

When I export the poduct (via the "Eclipse Product export wizard" of the product editor), it does build the product. I can launch the product, everything works fine (the plugin is there and doing what it is supposed to do).

The only problem is that the user of the product cannot install additional Eclipse features using the Software Update menu (Help -> Software Updates). The Software Updates sub-menus ("Find and Install..." and "Manage Configuration...") are grayed out.

What plugins and/or features are we supposed to add to the product so the product could accept additional features using the Software Updates menu ?

I tried to add a bunch of org.eclipse.equinox.p2.* plugins, but it is still not working.

  <plugin id="org.eclipse.equinox.p2.artifact.repository"/>
  <plugin id="org.eclipse.equinox.p2.console"/>
  <plugin id="org.eclipse.equinox.p2.core"/>
  <plugin id="org.eclipse.equinox.p2.director"/>
  <plugin id="org.eclipse.equinox.p2.director.app"/>
  <plugin id="org.eclipse.equinox.p2.directorywatcher"/>
  <plugin id="org.eclipse.equinox.p2.discovery"/>
  <plugin id="org.eclipse.equinox.p2.discovery.compatibility"/>
  <plugin id="org.eclipse.equinox.p2.engine"/>
  <plugin id="org.eclipse.equinox.p2.extensionlocation"/>
  <plugin id="org.eclipse.equinox.p2.garbagecollector"/>
  <plugin id="org.eclipse.equinox.p2.jarprocessor"/>
  <plugin id="org.eclipse.equinox.p2.metadata"/>
  <plugin id="org.eclipse.equinox.p2.metadata.repository"/>
  <plugin id="org.eclipse.equinox.p2.operations"/>
  <plugin id="org.eclipse.equinox.p2.publisher"/>
  <plugin id="org.eclipse.equinox.p2.publisher.eclipse"/>
  <plugin id="org.eclipse.equinox.p2.ql"/>
  <plugin id="org.eclipse.equinox.p2.reconciler.dropins"/>
  <plugin id="org.eclipse.equinox.p2.repository"/>
  <plugin id="org.eclipse.equinox.p2.repository.tools"/>
  <plugin id="org.eclipse.equinox.p2.touchpoint.eclipse"/>
  <plugin id="org.eclipse.equinox.p2.touchpoint.natives"/>
  <plugin id="org.eclipse.equinox.p2.transport.ecf"/>
  <plugin id="org.eclipse.equinox.p2.ui"/>
  <plugin id="org.eclipse.equinox.p2.ui.discovery"/>
  <plugin id="org.eclipse.equinox.p2.ui.importexport"/>
  <plugin id="org.eclipse.equinox.p2.updatechecker"/>
  <plugin id="org.eclipse.equinox.p2.updatesite"/>

Does someone know exactly what needs to be done (at the product definition level if possible) in order to get the Software Updates menu working ?

Baerl answered 13/9, 2012 at 20:14 Comment(0)
P
3

The menu entry 'Install new software' is contribued by plug-in org.eclipse.equinox.p2.ui.sdk. You should include it to show that menu entry in your RCP.

If your RCP is feature based, I think you should only include p2 related features to simplify the process.

Paradrop answered 17/9, 2012 at 6:50 Comment(2)
Adding org.eclipse.equinox.p2.ui.sdk did add the menu entry Install new software in my Eclipse product when testing it. Although the menu entry Install new software failed with error message "Could not locate the running profile instance. The eclipse.p2.data.area and eclipse.p2.profile properties may not be set correctly in this application's config.ini file.". To fix this I had to add org.eclipse.equinox.ds bundle.Baerl
@LoicO Can you say where I should add these <plugin> lines? which file ? ThanksKamala
S
0

I don't know the full list of required p2 bundles, but this is how you can easily generate it: Use the new wizard to create an e4 > e4 Application Project. This generates a product file that contains all bundles needed for an p2 updatable product.

If you have a feature-based product, the features org.eclipse.rcp and org.eclipse.e4.rcp should also give you an updatable product

Sherburne answered 17/9, 2012 at 7:4 Comment(1)
I use indigo, and I don't see e4. Also, my product is not a RCP application, just an Eclipse product (I guess I could say a branded Eclipse). Turns out that the 2 missing bundles were: org.eclipse.equinox.p2.ui.sdk and org.eclipse.equinox.ds. Thanks.Baerl
C
0

I was also face same issue and resolved by the following steps;

In the Product Configuration file,

.product file --> In Configuration Tab

Specify custom start levels for the following plug-ins,
    org.eclipse.equinox.ds start level 2, auto start true 
    org.eclipse.equinox.simpleconfigurator start level 1, auto start true
    org.eclipse.equinox.common start level 2, auto start true
    org.eclipse.core.runtime start level 4, auto start true
Corticosteroid answered 20/9, 2013 at 8:17 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.