Questions on p2.director [message #120760] |
Thu, 06 November 2008 10:33  |
Eclipse User |
|
|
|
Hi,
I have a couple questions on p2.director. I'm doing headless build on
linux. When I run p2.director as the last step to make a p2-enabled
archive, it tries to access eclipse.org. Since I just built my sources, I
just want it to retrieve what was built from another directory. How do I
make it to only look in a certain directory locally for what it needs?
Also, I'm getting some errors unzipping jar files due to invalid zip file
format during the run. Here is a sample snippet.
!MESSAGE Error closing the output stream for org.junit4/osgi.bundle/4.3.1
on repository
file:/home/ctbuilds/Eclipse_Builds_new/eclipse_build/fsl.ecl ipse/eclipse_p2/.
!STACK 0
java.io.IOException: Error unzipping /tmp/org.junit4_4.3.130706.jar:
Invalid zip file format
at
org.eclipse.equinox.internal.p2.core.helpers.FileUtils.unzip File(FileUtils.java:31)
at
org.eclipse.equinox.internal.p2.artifact.repository.simple.S impleArtifactRepository$ZippedFolderOutputStream.close(Simpl eArtifactRepository.java:146)
at java.io.FilterOutputStream.close(FilterOutputStream.java:143 )
Here is what I did to build:
1. I added the following into buildConfigs/sdk/build.properties
product=${buildDirectory}/sdk.product
generate.p2.metadata=true
p2.metadata.repo = file:${buildDirectory}/repo
p2.artifact.repo = file:${buildDirectory}/repo
p2.flavor = tooling
p2.publish.artifacts=true
generateVersionsList=true
2. copied buildConfigs/sdk/packager/sdk.product into buildDirectory and
modified @qualifier@ to "Test_Build". I also modified the postFetch step
in sdk's customTarger.xml so it doesn't use timestamp as qualifier for sdk
and platform archives. I'm not sure why it was set that way to begin with.
3. build. I use build.xml in eclipsebuilder. This generated the repo/*.xml
files and the simpleconfigurator directory under eclipse/configuration.
4. unzip the built archive to use as builder. run p2.director as follows.
eclipse_p2 is the new directory for the result.
../../../sun_java/j2sdk1.4.2_14/jre/bin/java
-Declipse.p2.data.area=./eclipse_p2/p2 -jar
/eclipse/plugins/org.eclipse.equinox.launcher_1.0.101.Test_B uild.jar
-data workspace -application
org.eclipse.equinox.p2.director.app.application -flavor tooling
-metadataRepository file:../repo -artifactRepository file:../repo
-installIU org.eclipse.sdk.ide -p2.os linux -p2.ws gtk -p2.arch x86
-profile SDKProfile -profileProperties
org.eclipse.update.install.features=true -destination ./eclipse_p2
-bundlepool ./eclipse_p2 -consoleLog -roaming
Is there something wrong with this process that caused p2.director to fail?
Thanks for any pointers.
Have a great day,
Eirene
|
|
|
|
|
|
Re: Questions on p2.director [message #120986 is a reply to message #120897] |
Mon, 10 November 2008 13:55  |
Eclipse User |
|
|
|
Hi,
I'm really bummed about p2-izing a build. It can't be this difficult! I'm
only trying to build the 3.4.1 sources!
I started my build from scratch to get a clean start. The sources were
checked out of eclipse cvs (R3_4_1 tag) and put into our repository to be
checked out from there during my build. I updated maps files for the new
location.
I built the sdk component with build.xml in eclipsebuilder. No
modifications to build.properties or anything.
After it's done I untar the archive and ran the following command line to
generate p2 metadata
../../../sun_java/j2sdk1.4.2_14/jre/bin/java -jar
/eclipse/plugins/org.eclipse.equinox.launcher_1.0.101.Test_B uild.jar
-data workspace -application
org.eclipse.equinox.p2.metadata.generator.EclipseGenerator -flavor tooling
-metadataRepository "file:../repo" -artifactRepository "file:../repo"
-root "Eclipse SDK" -rootVersion 3.4.1 -source ./eclipse -append
-publishArtifacts -publishArtifactRepository
Then ran the following for p2 director
../../../sun_java/j2sdk1.4.2_14/jre/bin/java
-Declipse.p2.data.area=./eclipse_p2/p2 -jar
/eclipse/plugins/org.eclipse.equinox.launcher_1.0.101.Test_B uild.jar
-data workspace -application
org.eclipse.equinox.p2.director.app.application -flavor tooling
-metadataRepository file:../repo -artifactRepository file:../repo
-installIU "Eclipse SDK" -version 3.4.1 -p2.os linux -p2.ws gtk -p2.arch
x86 -profile SDKProfile -profileProperties
org.eclipse.update.install.features=true -destination ./eclipse_p2
-bundlepool ./eclipse_p2 -consoleLog -roaming
In the eclipse_p2 folder, I got features, p2, and plugins folders but no
eclipse.exe or any other files that should be at that level. Also got the
verifying signature error I mentioned in the previous post.
Can someone tell me what's missing in my steps? Am I supposed to modify
something in the eclipse sources to have more info generated? I assumed
the sources were already set up properly to have everything needed for the
metadata generator and p2 director.
thanks,
Eirene
|
|
|
Powered by
FUDForum. Page generated in 0.09947 seconds