Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [equinox-dev] How to use p2.generator in PDE build


Torkild,
In addition to any manual calls you may want to make to the p2.generator, there is some integration with PDE.Build.
Unfortunately there is not yet any documentation here.

If the org.eclipse.equinox.p2.metadata.generator bundle is present in the builder at script generation time, then there are potentially 4N + 1 generated calls to the p2.generator.

For N configurations:
1) In the assemble.[feature].[config].xml scripts:        a) Once on assembled features and plugins
                                                 b) a second time on assembled rootfiles.
2) In the package.[feature].[config].xml scripts:        a) Once of the packaged features and plugins
                                                b) again on rootfiles from packaging
And one final call:
3) In the assemble.all.xml or package.all.xml : A final call to generate a root product IU

These calls are all conditional on the "generate.p2.metadata" property being set.  In the case of a product build, the final result at the end of these calls is a repo with an installable product IU.
To get an actual p2ized install out of this, you then need to call the p2.director on the repo and install

As an example, the SDK is built by first building a master zip containing everything.  p2.generator is called on this in a custom step to generate IUs for all the plugins and features.  Then the build runs the pde build packager with a .product file and metadata integration to assemble all the rootfiles and generate p2 data on them (steps 2 & 3 above).  Then finally in custom steps it calls p2.director to install the SDK and zip up the results.

-Andrew

Some properties to define are:
generate.p2.metadata=true
p2.metadata.repo = file:${buildDirectory}/repo
p2.artifact.repo = file:${buildDirectory}/repo
p2.metadata.repo.name = Meta Repo Name
p2.artifact.repo.name = Artifact Repo Name
p2.flavor = tooling
p2.publish.artifacts=true




John Arthorne/Ottawa/IBM@IBMCA
Sent by: equinox-dev-bounces@xxxxxxxxxxx

05/20/2008 10:27 AM

Please respond to
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>

To
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>
cc
Subject
Re: [equinox-dev] How to use p2.generator in PDE build






Hi Torkild,


Here is a document describing the metadata generator:


http://wiki.eclipse.org/Equinox_p2_Metadata_Generator


The ant task doesn't yet have documentation, but it takes the same arguments as the generator application. You just need to convert the command line syntax to Ant syntax. For an example, you could look at the Eclipse project scripts that p2-enable the platform itself. See /cvsroot/eclipse/org.eclipse.releng.eclipsebuilder/equinox/buildConfigs/equinox.prov/run.xml, particularly the "run.generator" target.


Feel free to annotate the wiki page with any other details you find useful.


John



Torkild Ulvøy Resheim <Torkild.Ulvoy-Resheim@xxxxxxxxx>
Sent by: equinox-dev-bounces@xxxxxxxxxxx

05/20/2008 09:50 AM

Please respond to
Equinox development mailing list <equinox-dev@xxxxxxxxxxx>

To
equinox-dev@xxxxxxxxxxx
cc
Subject
[equinox-dev] How to use p2.generator in PDE build







Hi all,

I'm in the process of migrating our Eclipse based product to Ganymede and have
a few issues with p2.

Building the product as usual using the PDE build scripts works nicely but
creates a product that cannot be updated as it states 'Cannot launch the
Update UI. This installation has not been configured properly for Software
Updates.'

After quite a lot of digging I've found that the product must be p2-ized which
seems like a good idea. I also found a reference to the "p2.generator" ANT
task but absolutely no information on how to use it.

Could someone please point me to the right direction here? I guess I must use
this task somewhere in customCallbacks.xml or the new customAssembly.xml but
I cannot figure out where and which attributes to set.
--
Torkild Ulvøy Resheim
Senior Design Engineer
Atmel Norway AS
_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev

_______________________________________________
equinox-dev mailing list
equinox-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/equinox-dev


Back to the top