Much ado about scripting, Linux & Eclipse: card subject to change


That Ol' PDE Black Magic

... or more reasons why features still suck.

In the past 24hrs, I've encountered two feature-related PDE issues, which I think warrant discussion as they are, to the uninitiated, seemingly black magic. The first of these was discovered and fixed last night while watching The Dresden Files in ten-minute chunks while waiting for builds to complete, but I'm sure that's just a coincidence.

Bug The Firste: feature.xml should not specify version numbers when including required plugins like org.eclipse.test [192231].

This issue manifests when your build stops working one day and complains, "eclipse/test.assembly/eclipse/plugins/${org.eclipse.test} not found." The fix is simple: make sure you set version="0.0.0" in your feature.xml when including org.eclipse.test or other plugins referenced in your map file and required by your build. See also Build Problems.

Bug The Seconde: PDE will build features in the order they're listed in feature.xml [192292].

This issue manifests when your source feature, for example, builds OK but contains no source because PDE is building it BEFORE your runtime feature(s). Once again, the fix is simple. You just have to reorder your feature.xml to put your source feature(s) last.

Bug The Thirde (Bonus Bug!): If your plugin or feature doesn't have the right Nature and Builder in its .project file, it won't behave the way you'd expect [192247] in Eclipse.

This one's a no-brainer, but also a handy tip when working with PDE. If your plugin project doesn't have the Plugin nature, you can't open a MANIFEST.MF file with the Manifest Editor; if your feature doesn't have the Feature nature, PDE won't give you warnings/errors if your feature is misconfigured (eg., if you have a version set to "o.o.o" instead of "0.0.0"). Just add something like this:



Chris Aniszczyk (zx) said...

"PDE Build" black magic please.

everyone loves PDE UI :D

Doug Schaefer said...

Guilt by association I guess ;)