Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Archived » Buckminster » multi-platform RCP build: from the PDE and headless
multi-platform RCP build: from the PDE and headless [message #799389] Wed, 15 February 2012 20:45 Go to next message
Edward Pershwitz is currently offline Edward PershwitzFriend
Messages: 10
Registered: February 2012
Junior Member
Disclaimer: After beating my head against the wall for days trying to set up what would seem to be a standard use case I feel like a Skinner box rat conditioned into the state of learned helplessness, so please take any inappropriate sarcasm as a sign of being overwhelmed rather than disrespect.

My ultimate goal is to set up a headless multi-platform multi-target build of an RCP product with additional pre-build and post-build tasks like running a regression on a test target and javadoc generation.

My immediate goal (that I'm miserably failing at) is to build and publish from the PDE using Buckminster and generate launchers for at least the three most common platforms: linux, windows, and macos-cocoa.

The BuckyBook reads exceptionally well and I diligently plowed through most of it. But the devil is in the details and "little technicalities" that have to be "figured out" by endless mindless trial and error are making this journey daunting to say the least.

So here goes:
Eclipse version: Indigo 3.7.0
Buckminster version: 1.4.0
Platforms: linux, windows, and mac
Build server: linux
Version control: Git

Following the BuckyBook "Building RCP products" chapter, one of the prerequisites says: "you must have the Eclipse Delta Pack installed in your IDE." I'm not sure I understand why it needs to be in my IDE when I really want it in my target (other than using my IDE installation in my target definition) especially since ultimately I want to build headlessly, but in the end I do need platform-specific fragments so the Delta Pack is one way of getting them.

The Delta Pack seems to be the best kept Eclipse secret: having the equinox.executable feature on the Indigo release p2 site would have been way too easy. But after much production and reading numerous forums I've located the download here: download.eclipse.org/eclipse/downloads/drops/R-3.7-201106131736/index.php. Adding the Delta pack to the target platform didn't work (and could not work really because the equinox.executable feature included there needs more fragments/plugins than the plugins directory has) so Eclipse only reports 16 available plugins (the rest are jars) and Buckminster naturally can't find them either and generates either "not known to Buckminster" or "<path>.jar is not a directory" error - I've tried this so many different ways that I can't remember the exact circumstances for each.

So, short of pulling the delta pack into my development environment and editing the equinox.executable feature to only include available platforms, or better yet the three platforms that I need and pruning extra plugins/fragments (an exercise that I'm still trying to avoid) I'm at a loss with the Delta Pack. I'm sure numerous people have successfully used it and my experience is due to my ignorance, but I have not been able to locate any consistent description of how to deal with it anywhere, and boy have I tried.

Luckily some other posts somewhere suggested to "include all environments" while building the target (apparently the modern way of mutli-platform build as compared to the Delta Pack) which did the trick of pulling in the required plugins/fragments except it didn't pull in the equinox.executable feature itself. Buckminster happily built and published the site (with os=*, ws=*, and arch=*) except no launchers were created. Testing the install from linux using a p2 installer from download.eclipse.org/equinox/drops/R-3.7-201106131736/index.php with properties appropriately tweaked installed everything except the binary launcher. If the launcher was borrowed from the installer itself (just copied over to the RCP installation) the installed RCP came up and ran beautifully.

As a side note the Equinox download page quoted above only has p2 installers for linux and windows under its p2 Provisioning Tools, but not for the mac. I wonder if this will become yet another tilting at windmills exercise when (and if) I manage to create a sane multi-platform build.

So back to creating the launchers... in this thread: www.eclipse.org/forums/index.php/t/237823/ Thomas Hallgren suggests that the equinox.executable feature can be had from this download site: download.eclipse.org/eclipse/updates/3.7, which does not appear to be the case... or at least I wasn't able to find it there. The "Add Software Site" wizard conveniently does not show component IDs but only component names, and none of these names suggest that they are this feature. I also looked at the properties page for most of them one by one (!!!) - apparently the only way you can human-speed-linear-search for a component with a known ID - and still no luck. So I resorted again to trying to pull the feature from the Delta Pack - bad idea. Not only did it still try to resolve components it didn't have (I was naively hoping that maybe "include all environments" would pull them in), it would mess up the target platform even after being removed from it, so that it had to be redefined from scratch to work again.

Additionally, defining the target platform to pull the rcp feature from the Indigo release site had an annoying side effect of Eclipse re-resolving the feature every time you want to look at the target platform apparently downloading the whole thing every time and freezing for minutes at a time. Is there a way to make it download once and use the local copy instead? It's not like the last year's release rcp feature would be changing too terribly often.

So here I am back at square one. Can someone help or at least point me to a source of consistent information on how to set up a multi-platform RCP build, preferably with reusable metadata managed by an Eclipse project so that it can then become the basis for a headless build? If I ever graduate to setting up a headless build, that is, since so far I'm miserably failing the class.

--Buckminster Community Member Wannabe
Re: multi-platform RCP build: from the PDE and headless [message #799674 is a reply to message #799389] Thu, 16 February 2012 06:58 Go to previous messageGo to next message
Thomas Hallgren is currently offline Thomas HallgrenFriend
Messages: 3240
Registered: July 2009
Senior Member
On 02/15/2012 09:45 PM, Edward Pershwitz wrote:
> Following the BuckyBook "Building RCP products" chapter, one of the prerequisites says: "you must have the Eclipse Delta
> Pack installed in your IDE."

This is an error in the BuckyBook. The delta-pack should have gone into the target platform. Today it's not needed at
all. Instead, you must ensure that the 'Equinox Executable' and the 'RCP' feature is in your target platform. The former
provides the executable launcher found in the root of your product. Both features contains launcher fragments for all
platforms and the RCP feature will also provide SWT fragments for all platforms. The delta pack used to provide all of
this in the old days.

Please note that the 'Equinox Executable' feature must be excluded from the final product. It's only intended for the
target platform.

Buckminster will trigger on the presence of these features and install all launchers etc. correctly in the final product.

I can recommend having a peek on how the build is set up for our Geppetto product if you want a good example of a
multi-platform RCP build, where the final product includes the p2 installer, and where the build also produces an update
site.

The source for Geppetto is at GitHub: https://github.com/cloudsmith/geppetto and the projects to look at are:

org.cloudsmith.geppetto.releng (the release engineering project)
org.cloudsmith.geppetto.product-feature
org.cloudsmith.geppetto (the branding plug-in)
org.cloudsmith.geppetto.site (defines the Geppetto Update Site)

I hope this can be of help. Please enter a bugzilla to get the mention of "delta-pack" corrected in the book.

Kind Regards,
Thomas Hallgren
Re: multi-platform RCP build: from the PDE and headless [message #800105 is a reply to message #799674] Thu, 16 February 2012 17:44 Go to previous messageGo to next message
Edward Pershwitz is currently offline Edward PershwitzFriend
Messages: 10
Registered: February 2012
Junior Member
Thomas,

Thanks for a quick reply. I managed to get the build to work last night. I just needed to change my thinking from "eclipse" to "buckminster" and rather than relying on eclipse to materialize the target from a shared target definition use the RMAP and let Buckminster materialize the entire target from feature dependencies. Worked like a charm and installed correctly on both linux and windows. The only wrinkle is mac installation but I should be able to find an installer.

> Please enter a bugzilla to get the mention of "delta-pack" corrected in the book.
Please see https : // bugs.eclipse.org/bugs/show_bug.cgi?id=371789 (I'm not allowed to post links yet, hence the extra spaces)

> Please note that the 'Equinox Executable' feature must be excluded from the final
> product. It's only intended for the target platform.
The way I dealt with this is including o.e.e.executable in the actual releng feature. This way it's "above" the product dependency tree and so it makes it into the target but not the installed product. I know that in one of your prior posts you mentioned putting it into CSPEC/CSPEX. Do you see a problem with my approach as compared with CSPEC?

Thanks for pointing me to geppetto. Nothing better than seeing how the principles do things to pick the best practices. Thanks!

Edward
Re: multi-platform RCP build: from the PDE and headless [message #800151 is a reply to message #800105] Thu, 16 February 2012 19:06 Go to previous message
Thomas Hallgren is currently offline Thomas HallgrenFriend
Messages: 3240
Registered: July 2009
Senior Member
On 02/16/2012 06:44 PM, Edward Pershwitz wrote:
> Please see https : // bugs.eclipse.org/bugs/show_bug.cgi?id=371789 (I'm not allowed to post links yet, hence the extra
> spaces)
>
Thanks.

> The way I dealt with this is including o.e.e.executable in the actual releng feature. This way it's "above" the product
> dependency tree and so it makes it into the target but not the installed product. I know that in one of your prior posts
> you mentioned putting it into CSPEC/CSPEX. Do you see a problem with my approach as compared with CSPEC?
>
No, no problem. We use a cspec in our build because our releng project is not a feature project, but I see nothing wrong
in that.

- thomas
Previous Topic:How to I specify an ssh key passphrase when using headless Buckminster?
Next Topic:buckminster.postbind?
Goto Forum:
  


Current Time: Tue Mar 19 06:15:59 GMT 2024

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

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

Back to the top