Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » Headless build fails when unpack="true"
Headless build fails when unpack="true" [message #602298] Tue, 06 October 2009 19:37 Go to next message
Phil Denis is currently offline Phil DenisFriend
Messages: 26
Registered: October 2009
Junior Member
I have been using the ant scripts provided in org.eclipse.pde.build for some time to build update sites hosting plugins and features, however, now I have a plugin that NEEDS to be unpacked when it is installed.

In the feature manifest, I have listed the plugin with unpack="true". Now the ant build fails with the following message:

[exec] /var/cruise/projects/updatesite-test/allElements.xml:31: The following error occurred while executing this line:
[exec] /var/cruise/projects/updatesite-test/package.ca.richer.hello world.feature.xml:99: The following error occurred while executing this line:
[exec] /var/cruise/projects/updatesite-test/package.ca.richer.hello world.feature.xml:123: /var/cruise/projects/updatesite-test/tmp/plugins/ca.richer.h elloworld_1.0.0.I20091006 not found.

The ant target that was generated in package.ca.richer.helloworld.feature.xml is as follows:
<target name="assemble.archive">
<antcall target="customAssembly">
<param name="customTarget" value="pre.archive"/>
<param name="rootFolder" value="${eclipse.base}/ANY.ANY.ANY/${collectingFolder}"/>
</antcall>
<zip destfile="${archiveFullPath}" filesonly="false" whenempty="skip" update="true">
<zipfileset dir=" ${eclipse.base}/plugins/ca.richer.helloworld_1.0.0.I20091006 " prefix="${pluginArchivePrefix}/ca.richer.helloworld_1.0.0.I20091006 " />
</zip>
</target>

However, the contents of the plugins directory only contains the jarr'ed version of my plugin. It does not have the plugin in an unjarred directory structure. But, the updatesite should contain just the jar and the unpacking should be done when it is installed.

Anyone have any success using the updatesite builder with unpack="true"?? Do I need to write additional custom targets to "explode" my jar in the plugins folder?

I've tried with the build scripts provided with Eclipse 3.4.1 and 3.5 with the exact same results...

Thanks,
Phil
Re: Headless build fails when unpack="true" [message #602303 is a reply to message #602298] Wed, 07 October 2009 10:18 Go to previous messageGo to next message
Thorsten Meinl is currently offline Thorsten MeinlFriend
Messages: 85
Registered: July 2009
Member
Hi Phil,

We have quite a lot of plugins that need to be unpacked upon installation.
Building them and the Update Site works fine. Note, that the unpack
instructions must be in the auto-generated content.xml, the ones in the
feature are *not* used when installing the plugin.

Thorsten
Re: Headless build fails when unpack="true" [message #602342 is a reply to message #602298] Thu, 08 October 2009 17:03 Go to previous messageGo to next message
Phil Denis is currently offline Phil DenisFriend
Messages: 26
Registered: October 2009
Junior Member
Thanks for the reply Thorsten. So, in your feature.xml files do you have the plugins listed with unpack="true"? That seems to screw up my updatesite zip file, because it zips up the directory structure of the plugins instead of the jar for the plugin. I am running the p2 generator afterwards, which I'm hoping puts the unpack instructions into the content.xml file.

If I could just get the build to include the jar version of the plugins and the content.xml file to include the unpack instructions, then I'd be set. Is there some way of getting content.xml to include the unpack instructions other than putting unpack="true" in the feature manifest?
Re: Headless build fails when unpack="true" [message #602357 is a reply to message #602298] Thu, 08 October 2009 20:27 Go to previous messageGo to next message
Phil Denis is currently offline Phil DenisFriend
Messages: 26
Registered: October 2009
Junior Member
Ok problem solved. If anyone else comes across this post, here's how it "should be":

1) feature.xml file should have the plugin listed with unpack set to true
2) the build.properties for the headless build should have outputUpdateJars set to true ... if it is not true, the zip file created during the build will contain the exploded directory structure of the plugin you want unpacked.
Re: Headless build fails when unpack="true" [message #602581 is a reply to message #602298] Fri, 16 October 2009 21:40 Go to previous message
Andrew Niefer is currently offline Andrew NieferFriend
Messages: 990
Registered: July 2009
Senior Member
This seems to be bug https://bugs.eclipse.org/bugs/show_bug.cgi?id=265471
I thought it was fixed, but the bug is still open, so I guess not.

-Andrew
Phil Denis wrote:
> I have been using the ant scripts provided in org.eclipse.pde.build for
> some time to build update sites hosting plugins and features, however,
> now I have a plugin that NEEDS to be unpacked when it is installed.
>
> In the feature manifest, I have listed the plugin with unpack="true".
> Now the ant build fails with the following message:
>
> [exec] /var/cruise/projects/updatesite-test/allElements.xml:31: The
> following error occurred while executing this line:
> [exec] /var/cruise/projects/updatesite-test/package.ca.richer.hello
> world.feature.xml:99: The following error occurred while executing this
> line:
> [exec] /var/cruise/projects/updatesite-test/package.ca.richer.hello
> world.feature.xml:123:
> /var/cruise/projects/updatesite-test/tmp/plugins/ca.richer.h
> elloworld_1.0.0.I20091006 not found.
>
> The ant target that was generated in
> package.ca.richer.helloworld.feature.xml is as follows:
> <target name="assemble.archive">
> <antcall target="customAssembly">
> <param name="customTarget" value="pre.archive"/>
> <param name="rootFolder"
> value="${eclipse.base}/ANY.ANY.ANY/${collectingFolder}"/>
> </antcall>
> <zip destfile="${archiveFullPath}" filesonly="false"
> whenempty="skip" update="true">
> <zipfileset dir="
> ${eclipse.base}/plugins/ca.richer.helloworld_1.0.0.I20091006 "
> prefix="${pluginArchivePrefix}/ca.richer.helloworld_1.0.0.I20091006
> " />
> </zip>
> </target>
>
> However, the contents of the plugins directory only contains the jarr'ed
> version of my plugin. It does not have the plugin in an unjarred
> directory structure. But, the updatesite should contain just the jar
> and the unpacking should be done when it is installed.
>
> Anyone have any success using the updatesite builder with
> unpack="true"?? Do I need to write additional custom targets to
> "explode" my jar in the plugins folder?
>
> I've tried with the build scripts provided with Eclipse 3.4.1 and 3.5
> with the exact same results...
>
> Thanks,
> Phil
Previous Topic:Headless build fails when unpack="true"
Next Topic:How to configure headless PDEbuild to build not in the source folder
Goto Forum:
  


Current Time: Sat Sep 21 11:47:36 GMT 2024

Powered by FUDForum. Page generated in 0.03580 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top