bajrang
bajrang

Reputation: 51

Eclipse: Virgo tooling plugin installation using P2 directory

I am trying to install Virgo tooling Eclipse plugin using the P2 installation directory, since I want to install directly from command line and not from GUI. I am getting the below error and seems like some dependencies issues are there. I tried resolving the dependencies but I am still facing the same issue. I also searched on the web and was not able to find a good solution for the issue.

Cannot complete the install because one or more required items could not be found.
 Software being installed: Eclipse Virgo Tools 1.5.0.R01-RELEASE (org.eclipse.virgo.ide.feature.feature.group 1.5.0.R01-RELEASE)
 Missing requirement: Eclipse Virgo IDE (Server Core) 1.5.0.R01-RELEASE (org.eclipse.virgo.ide.runtime.core 1.5.0.R01-RELEASE) requires 'bundle org.json 0.0.0' but it could not be found
 Cannot satisfy dependency:
  From: Eclipse Virgo Tools 1.5.0.R01-RELEASE (org.eclipse.virgo.ide.feature.feature.group 1.5.0.R01-RELEASE)
  To: org.eclipse.virgo.ide.runtime.core [1.5.0.R01-RELEASE]

Please note that the plugin installation works from the Eclipse GUI. I also installed other plugins from command line and that worked, only facing issue with Virgo tooling plugin.

Upvotes: 0

Views: 214

Answers (1)

GianMaria Romanato
GianMaria Romanato

Reputation: 132

The Virgo Tools depend on the Virgo server and several other Eclipse projects. When installing from the command line using p2 director you have to specify the comma separated list of features to install and the list of p2 repositories containing such features (and dependencies).

The following is an example for creating an Eclipse + Virgo Tools starting from the Neon RCP runtime distribution and adding JDT, egit, Web Tools etc. etc.

I created it from a working script I have, removing some very specific plug-ins I use. You may want to have a look at it as an example, I do not guarantee it works after the modification.

If instead of starting from Neon RCP you start from Neon for JavaEE developers you can remove most of the features and repositories.

#!/bin/sh

./eclipse -nosplash -debug -consolelog -application org.eclipse.equinox.p2.director\
 -i \
org.eclipse.recommenders.rcp.feature.feature.group,\
org.eclipse.recommenders.mylyn.rcp.feature.feature.group,\
org.eclipse.egit.feature.group,\
org.eclipse.egit.gitflow.feature.feature.group,\
org.eclipse.egit.mylyn.feature.group,\
org.eclipse.mylyn.github.feature.feature.group,\
org.eclipse.jdt.feature.group,\
org.eclipse.jst.enterprise_ui.feature.feature.group,\
org.eclipse.jst.web_ui.feature.feature.group,\
org.eclipse.virgo.ide.feature.feature.group,\
org.eclipse.wst.web_ui.feature.feature.group,\
org.eclipse.wst.xml_ui.feature.feature.group,\
org.eclipse.wst.xsl.feature.feature.group,\
org.eclipse.emf.sdk.feature.group,\
org.eclipse.wst.jsdt.feature.feature.group,\
org.eclipse.m2e.feature.feature.group,\
org.eclipse.epp.mpc.feature.group,\
org.eclipse.mylyn.hudson.feature.group,\
org.eclipse.mylyn.ide_feature.feature.group,\
org.eclipse.mylyn.java_feature.feature.group,\
org.eclipse.mylyn.pde_feature.feature.group,\
org.eclipse.mylyn.team_feature.feature.group,\
org.eclipse.mylyn.gerrit.feature.feature.group,\
org.eclipse.mylyn.gerrit.dashboard.feature.feature.group,\
org.eclipse.mylyn_feature.feature.group,\
org.eclipse.mylyn.context_feature.feature.group,\
org.eclipse.mylyn.bugzilla_feature.feature.group,\
org.eclipse.mylyn.git.feature.group,\
org.eclipse.mylyn.wikitext_feature.feature.group,\
org.eclipse.tm.terminal.feature.feature.group,\
org.sonatype.tycho.m2e.feature.feature.group,\
org.sonatype.m2e.egit.feature.feature.group,\
org.jboss.tools.m2e.jdt.feature.feature.group,\
org.sonatype.m2e.sisu.feature.feature.group,\
 -r \
http://download.eclipse.org/releases/neon,\
http://download.eclipse.org/virgo/release/tooling,\
http://download.eclipse.org/recommenders/updates/stable/,\
http://download.eclipse.org/technology/m2e/releases/,\
http://download.eclipse.org/tools/orbit/downloads/drops/R20160520211859/repository/,\
http://repo1.maven.org/maven2/.m2e/connectors/m2eclipse-egit/0.14.0/N/LATEST/,\
http://repo1.maven.org/maven2/.m2e/connectors/m2eclipse-tycho/0.8.0/N/LATEST/,\
http://repo1.maven.org/maven2/.m2e/connectors/m2eclipse-sisu/0.15.0/N/LATEST/,\
http://download.jboss.org/jbosstools/updates/m2e-extensions/m2e-jdt-compiler/1.0.1-2012-09-20_05-03-18-H2/,\
http://download.eclipse.org/eclipse/updates/4.2/

Comments:

  • the above is a *unix shell script (runs fine on MacOs).
  • the \ character at the end of each line is required because this is a shell command that continues for multiple lines
  • -i is the p2 parameter for specifying a comma separated list of features to be installed
  • -r is the p2 parameter for specifying a comma separated list of repositories to be used for locating features and dependencies

Disclaimer: I am an Eclipse Virgo committer.

Upvotes: 0

Related Questions