[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
RE: [p2-dev] Problem using p2 to install plugin
- From: <Warren_Paul@xxxxxxx>
- Date: Thu, 23 Jul 2009 15:56:39 -0400
- Delivered-to: firstname.lastname@example.org
- Thread-index: AcoLyN7ZQeWCbYqNQHiaFYFa3EIj8wABag2g
- Thread-topic: [p2-dev] Problem using p2 to install plugin
I am not a p2 export or committer but I have been playing
with p2 for quite a while.
I think you are on the right lines.
<feature>.feature.group is p2 metadata. You don't get this building
your feature in eclipse IDE. As you have discovered you need to export
your feature with p2 metadata or, preferably I would think - at least for releng
anyways, use antrunner and pde build's build.xml to build the feature adding the
following to your build.properties file:-
p2.metadata.repo = file:/path/to/your/destination
This should build you feature and publish a p2
repo to file:/path/to/your/destination
You should then be able to install the feature
through 'Install New Software' by adding file:/path/to/your/destination as
a new location.
I know that the "-dev" mailing
lists are not meant for user problems, but there doesn't seem to be a
p2-specific user newsgroup. Please feel free to tell me where to go, if I'm in
the wrong place. :)
I have a feature that was
originally developed for Eclipse 3.2 and has been working with minor bug fixes
ever since. We want to support Eclipse 3.5, and the only ways I can manage to
get it enabled are somewhat hacky.
The following install
procedures both work smoothly:
2) Enable the "Classic Update"
capability in preferences, and add an extension location that points to the same
<install directory> as above.
Neither of these are very good
options for us to tell our customers to use. Besides, we'd like to keep up with
the times and make our feature/plugins "p2 enabled".
Using the new "Install New
Software" in Eclipse 3.5, adding the location above as a site, and choosing to
install our feature, I get the following error message: "Cannot complete the
install because one or more required items could not be found.
1248373809037 0.0.0.1248373809037 requires '<feature id>.feature.group
[4.10.0]' but it could not be found" (where <feature id> is the symbolic
name of my feature, and 4.10.0 is the version # for everything involved).
Now, there's nothing named
"<feature id>.feature.group" in any of my Manifest.mf or feature.xml
files, but from 2 days of web searches and trying various things, this id
appears to be part of the metadata that p2 generates when there are no
pre-generated content.xml or artifacts.xml files in the install location. The
thing is, I get basically the same message after using the export wizard on my
feature, generating the content.xml and artifacts.xml files, when trying to
install from the exported location. The number at the beginning of that error
message appears to be the timestamp from the time I attempted the install, since
it changes each time I try. However, that number is never the same as the value
in p2.timestamp in the generated content.xml file. I tried using the
FeaturesAndBundlesPublisher from the command line, and unsuprisingly, that
didn't seem to really make any difference in the content of the .xml
All of my plugins and plugin
fragments are at the same revision as my feature (4.10.0). My feature "includes"
3 plugins, one of which depends on the other (the 3rd is a help page), and 2
plugin fragments for localization. I've tried removing the plugin fragments, in
case those were the nameless thing causing the failed dependency, but that made
no difference. How can I figure out what it is that is causing the failed
dependency? The error shows up in the log 4 times, which seems like once for the
feature, and once for each of the plugins, but that's just speculation on my
part. If there's no easy answer, I'm willing to step through the installer code
to try to figure this out, but I don't know where to start. Which project should
I be checking out of CVS? I couldn't find anything labelled
org.eclipse.equinox.p2, but I might be going blind.