Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Plugin Development Environment (PDE) » headless PDE build: how can I force resolution of a modified plugin?
headless PDE build: how can I force resolution of a modified plugin? [message #63620] Thu, 28 May 2009 20:09 Go to next message
William R. Swanson is currently offline William R. SwansonFriend
Messages: 10
Registered: July 2009
Junior Member
I'm using Eclipse 3.4.2 to do a headless PDE build
for a product where I'm importing a standard plugin
(org.eclipse.cdt.make.ui) as a source project and making
some minor changes to the plugin code.

What I'm seeing is that when I export the product from
within Eclipse (File->Export, Eclipse Product), it builds
as expected and the standard CDT plugin is replaced
with my modified version.

When running a headless build, however, the behavior isn't
determinstic: on some runs it's replaced and on other runs
the original version of the plugin is picked up.

Is there a way to force the headless build to resolve
the plugin correctly, or equivalently is there something
else I need to do (like specify a dependency or a
different version number on the modified plugin)?


Currently, my modified CDT plugin has the same version
number as the original; I've tried changing the version number
(e.g. incrementing it to 5.0.2, etc.) but this does not work
because something (maybe the CDT feature) is still looking
for the original version:

Problems during export
Unable to find plug-in: org.eclipse.cdt.make.ui_5.0.1.200902130801. Please
check the error log for more details.
Unable to find plug-in: org.eclipse.cdt.make.ui_5.0.1.200902130801. Please
check the error log for more details.


The product is defined as one feature, which includes the
modified plugin together with some other custom plugins.
The feature also includes the two "platform" features
(org.eclipse.cdt, org.eclipse.platform), and the product
invokes the org.eclipse.ui.ide.workbench application.


When I compare the output of a successful headless run with
a failed headless run, it appears that the eclipse.generateFeature
task is attempting to resolve the modified plugin, since I always
see the following in the build log output:

generateFeature:
[eclipse.generateFeature] Some inter-plug-in dependencies have not been
satisfied.
[eclipse.generateFeature] Bundle org.eclipse.cdt.make.ui:
[eclipse.generateFeature] Another singleton version selected:
org.eclipse.cdt.make.ui_5.0.1.200902130801

In the generated "build.xml" file for the feature, I see that
the "all.plugins" target either does or does not include
an entry for the modified CDT plugin, based on how the
plugin gets resolved.

<target name="all.plugins" depends="init">
<ant antfile="build.xml" dir="../../plugins/org.eclipse.cdt.make.ui"
target="${target}">
<property name="arch" value="x86"/>
<property name="ws" value="gtk"/>
<property name="os" value="linux"/>
</ant>
... other custom plugins ...
</target>


Any suggestions on what I should change to get the
modified plugin to be resolved consistently?
It's almost there, it's like I only need to specify
one more constraint to make it happen. :-)

--- WRS
Re: headless PDE build: how can I force resolution of a modified plugin? [message #63643 is a reply to message #63620] Fri, 29 May 2009 07:30 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: mickael.istria.openwide.fr

Hello William.

William R. Swanson a écrit :
> Is there a way to force the headless build to resolve
> the plugin correctly, or equivalently is there something
> else I need to do (like specify a dependency or a
> different version number on the modified plugin)?

Have you tried to set a specific version for your plugin (for example
3.0.2.patched or 3.0.3) and to specify in your .product or feature.xml
that you wish to use this version ?

HTH
Mickael
Re: headless PDE build: how can I force resolution of a modified plugin? [message #63664 is a reply to message #63643] Fri, 29 May 2009 14:31 Go to previous messageGo to next message
William R. Swanson is currently offline William R. SwansonFriend
Messages: 10
Registered: July 2009
Junior Member
Thanks much for the suggestion --

Yes, I did try setting a different version in the modified plugin,
but as noted in my original post I still saw a message reporting
that something (perhaps the CDT feature) was still looking for
the old version number, which is why I'm wondering if there's
some way of forcing the build to always resolve plugins against
the new version.

I didn't try setting a specific version in my feature definition,
so that's worth a try, but if the above dependency is coming
from something else this might not make a difference.

--- WRS

"Mickael Istria" <mickael.istria@openwide.fr> wrote in message
news:4A1F8F2D.2080505@openwide.fr...
> Hello William.
>
> William R. Swanson a
Re: headless PDE build: how can I force resolution of a modified plugin? [message #64119 is a reply to message #63620] Thu, 04 June 2009 20:48 Go to previous messageGo to next message
William R. Swanson is currently offline William R. SwansonFriend
Messages: 10
Registered: July 2009
Junior Member
For the record, after working with this for a bit, I came up with
the following method which seems to do what I want:

- determine the "feature" hierarchy that contains the
plugin you want to modify; in my case it was

org.eclipse.cdt (feature) contains
org.eclipse.cdt.platform (feature) contains
org.eclipse.cdt.make.ui (plugin)

- import each parent feature as a binary feature project
- import the plugin to be modified as a plugin project with source
- increment the version number on the plugin project
- in the parent feature's "Plug-ins" page,
specify that incremented version for the edited plugin
instead of the wildcard "0.0.0"
- do the same thing for each containing feature project
(increment the feature's version number, and specify
that number explicitly in the parent feature's
"Included Features" page)
- I'm using a topmost containing feature project to define my product;
in that feature project I just needed to add a reference to the topmost
feature project (org.eclipse.cdt), specifying the new version number.

This appears to cause the headless PDE build process to correctly
pick up the modified features/plugins for my build, but still pick up
the original features/plugins for the rest of CDT. I'm assuming the
same trick would work if I needed to modify a plugin from
the Eclipse platform as well.

This feels somewhat reasonable, and produces the right result,
though I'd be concerned if the feature hierarchy was much deeper
and I had to import a lot more feature projects.

If this method is obviously broken somehow, or if someone knows
a more efficient way to do this, please let me know!

--- WRS


"William R. Swanson" <traveler@tilera.com> wrote in message
news:gvmr19$t2l$1@build.eclipse.org...
> I'm using Eclipse 3.4.2 to do a headless PDE build
> for a product where I'm importing a standard plugin
> (org.eclipse.cdt.make.ui) as a source project and making
> some minor changes to the plugin code.
>
> What I'm seeing is that when I export the product from
> within Eclipse (File->Export, Eclipse Product), it builds
> as expected and the standard CDT plugin is replaced
> with my modified version.
>
> When running a headless build, however, the behavior isn't
> determinstic: on some runs it's replaced and on other runs
> the original version of the plugin is picked up.
>
> Is there a way to force the headless build to resolve
> the plugin correctly, or equivalently is there something
> else I need to do (like specify a dependency or a
> different version number on the modified plugin)?
> ...
Re: headless PDE build: how can I force resolution of a modified plugin? [message #479568 is a reply to message #64119] Tue, 11 August 2009 15:08 Go to previous message
YANCULOVICI is currently offline YANCULOVICIFriend
Messages: 18
Registered: July 2009
Junior Member
Hi William,

I'm encountering the same problem of making a headless build for a set of
plugins, including third-party "patched" plugins (e.g. org.eclipse.cdt.ui).

I'm new to headless build. I've follow the
http://wiki.eclipse.org/Common_Build_Infrastructure/Getting_ Started/Build_In_Eclipse
tutorial.

In my case the build process also try to build with the non-patched
(original) version of the third-party plugins. This lead to errors.

I've tried another way than your to bypass these errors: I've only
modified the patched plugins version (adding ".<my_sw>") and then,
specified to my topmost feature the included patched plugins with these
new versions.

Then the build process ends successfully. But if I try to install the
resulting plugins & features from the update manager, the installation
can't complete:

"
Cannot complete the install because of a conflicting dependency.
Software being installed: <my_sw>
0.2.0.v200908111552-7G53F7F6Zrz0neKKKllR (<my_sw>.feature.group
0.2.0.v200908111552-7G53F7F6Zrz0neKKKllR)
Software currently installed: Eclipse IDE for C/C++ Developers
1.2.0.20090615-0818 (epp.package.cpp 1.2.0.20090615-0818)
Only one of the following can be installed at once:
C/C++ Development Tools UI 5.1.0.opentlm (org.eclipse.cdt.ui
5.1.0.<my_sw>)
C/C++ Development Tools UI 5.1.0.200906161748 (org.eclipse.cdt.ui
5.1.0.200906161748)
"

The manual installation works and the two versions of the third-party
plugins (e.g. org.eclipse.cdt.ui patched and non-patched) coexist without
any problem.

The difference with you seems to be that I don't make a product but just a
set of plugins.

Did you try to make an update site for your plugins (including patched
ones) instead of a full product ?



Dimitri.
Re: headless PDE build: how can I force resolution of a modified plugin? [message #597966 is a reply to message #63620] Fri, 29 May 2009 07:30 Go to previous message
Mickael Istria is currently offline Mickael IstriaFriend
Messages: 865
Registered: July 2009
Location: Grenoble, France
Senior Member

Hello William.

William R. Swanson a écrit :
> Is there a way to force the headless build to resolve
> the plugin correctly, or equivalently is there something
> else I need to do (like specify a dependency or a
> different version number on the modified plugin)?

Have you tried to set a specific version for your plugin (for example
3.0.2.patched or 3.0.3) and to specify in your .product or feature.xml
that you wish to use this version ?

HTH
Mickael
Re: headless PDE build: how can I force resolution of a modified plugin? [message #597973 is a reply to message #63643] Fri, 29 May 2009 14:31 Go to previous message
William R. Swanson is currently offline William R. SwansonFriend
Messages: 10
Registered: July 2009
Junior Member
Thanks much for the suggestion --

Yes, I did try setting a different version in the modified plugin,
but as noted in my original post I still saw a message reporting
that something (perhaps the CDT feature) was still looking for
the old version number, which is why I'm wondering if there's
some way of forcing the build to always resolve plugins against
the new version.

I didn't try setting a specific version in my feature definition,
so that's worth a try, but if the above dependency is coming
from something else this might not make a difference.

--- WRS

"Mickael Istria" <mickael.istria@openwide.fr> wrote in message
news:4A1F8F2D.2080505@openwide.fr...
> Hello William.
>
> William R. Swanson a
Re: headless PDE build: how can I force resolution of a modified plugin? [message #598107 is a reply to message #63620] Thu, 04 June 2009 20:48 Go to previous message
William R. Swanson is currently offline William R. SwansonFriend
Messages: 10
Registered: July 2009
Junior Member
For the record, after working with this for a bit, I came up with
the following method which seems to do what I want:

- determine the "feature" hierarchy that contains the
plugin you want to modify; in my case it was

org.eclipse.cdt (feature) contains
org.eclipse.cdt.platform (feature) contains
org.eclipse.cdt.make.ui (plugin)

- import each parent feature as a binary feature project
- import the plugin to be modified as a plugin project with source
- increment the version number on the plugin project
- in the parent feature's "Plug-ins" page,
specify that incremented version for the edited plugin
instead of the wildcard "0.0.0"
- do the same thing for each containing feature project
(increment the feature's version number, and specify
that number explicitly in the parent feature's
"Included Features" page)
- I'm using a topmost containing feature project to define my product;
in that feature project I just needed to add a reference to the topmost
feature project (org.eclipse.cdt), specifying the new version number.

This appears to cause the headless PDE build process to correctly
pick up the modified features/plugins for my build, but still pick up
the original features/plugins for the rest of CDT. I'm assuming the
same trick would work if I needed to modify a plugin from
the Eclipse platform as well.

This feels somewhat reasonable, and produces the right result,
though I'd be concerned if the feature hierarchy was much deeper
and I had to import a lot more feature projects.

If this method is obviously broken somehow, or if someone knows
a more efficient way to do this, please let me know!

--- WRS


"William R. Swanson" <traveler@tilera.com> wrote in message
news:gvmr19$t2l$1@build.eclipse.org...
> I'm using Eclipse 3.4.2 to do a headless PDE build
> for a product where I'm importing a standard plugin
> (org.eclipse.cdt.make.ui) as a source project and making
> some minor changes to the plugin code.
>
> What I'm seeing is that when I export the product from
> within Eclipse (File->Export, Eclipse Product), it builds
> as expected and the standard CDT plugin is replaced
> with my modified version.
>
> When running a headless build, however, the behavior isn't
> determinstic: on some runs it's replaced and on other runs
> the original version of the plugin is picked up.
>
> Is there a way to force the headless build to resolve
> the plugin correctly, or equivalently is there something
> else I need to do (like specify a dependency or a
> different version number on the modified plugin)?
> ...
Re: headless PDE build: how can I force resolution of a modified plugin? [message #600522 is a reply to message #64119] Tue, 11 August 2009 15:08 Go to previous message
YANCULOVICI is currently offline YANCULOVICIFriend
Messages: 18
Registered: July 2009
Junior Member
Hi William,

I'm encountering the same problem of making a headless build for a set of
plugins, including third-party "patched" plugins (e.g. org.eclipse.cdt.ui).

I'm new to headless build. I've follow the
http://wiki.eclipse.org/Common_Build_Infrastructure/Getting_ Started/Build_In_Eclipse
tutorial.

In my case the build process also try to build with the non-patched
(original) version of the third-party plugins. This lead to errors.

I've tried another way than your to bypass these errors: I've only
modified the patched plugins version (adding ".<my_sw>") and then,
specified to my topmost feature the included patched plugins with these
new versions.

Then the build process ends successfully. But if I try to install the
resulting plugins & features from the update manager, the installation
can't complete:

"
Cannot complete the install because of a conflicting dependency.
Software being installed: <my_sw>
0.2.0.v200908111552-7G53F7F6Zrz0neKKKllR (<my_sw>.feature.group
0.2.0.v200908111552-7G53F7F6Zrz0neKKKllR)
Software currently installed: Eclipse IDE for C/C++ Developers
1.2.0.20090615-0818 (epp.package.cpp 1.2.0.20090615-0818)
Only one of the following can be installed at once:
C/C++ Development Tools UI 5.1.0.opentlm (org.eclipse.cdt.ui
5.1.0.<my_sw>)
C/C++ Development Tools UI 5.1.0.200906161748 (org.eclipse.cdt.ui
5.1.0.200906161748)
"

The manual installation works and the two versions of the third-party
plugins (e.g. org.eclipse.cdt.ui patched and non-patched) coexist without
any problem.

The difference with you seems to be that I don't make a product but just a
set of plugins.

Did you try to make an update site for your plugins (including patched
ones) instead of a full product ?



Dimitri.
Previous Topic:Troubling messages during 'p2.gathering' build
Next Topic:Reuse of PDE project creation operations
Goto Forum:
  


Current Time: Sat Apr 27 04:17:18 GMT 2024

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

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

Back to the top