You are viewing gcsaba2

Tired of ads? Upgrade to paid account and never see ads again!

Previous Entry

This is a quick overview of how to build products using Eclipse 3.6 (Helios) PDE builder.

First of all, you need to download Eclipse. Then go to the Software installation window and install "RCP Development resources" (or just anything with the word RCP in it). Installing the RCP delta pack is necessary for having an exe file. Without it, you can build the product, but your final ZIP file will only contain all the files, but not the EXE.

Create a directory called "builder". In it, create a subdirectory called "buildDirectory". Then create two new subdirectories: features and products. In the end, you should have the following directory structure:

+-- builder
+--+-- buildDirectory
   +---- features
   +---- plugins


Copy all your features into the features, and all your plugins and products into the plugins directory.

Finally, you need to write a build configuration script that tells the PDE builder what to do. Name this file "build.properties" and put it in the "builder" directory.

You can find a template for that file in your C:\eclipse\plugins\org.eclipse.pde.build_3.6.1.R36x_v20100823\templates\headless-build directory. I've taken this template, removed the unnecessary garbage, and this is what I got:

product=path/to/the/product/file
runPackager=true
archivePrefix=eclipse
collectingFolder=${archivePrefix}
configs=win32, win32, x86
allowBinaryCycles = true
flattenDependencies = true
zipargs=
tarargs=
buildDirectory=path/to/the/builder/buildDirectory
buildType=I
buildId=$buildId
buildLabel=${buildType}.${buildId}
timestamp=007
base=C:
baseLocation=${base}/eclipse
baseos=win32
basews=win32
basearch=x86
filteredDependencyCheck=false
resolution.devMode=false
skipBase=true
eclipseURL=
eclipseBuildId=
eclipseBaseURL=${eclipseURL}/eclipse-platform-${eclipseBuildId}-win32.zip
skipMaps=true
mapsRepo=:pserver:anonymous@example.com/path/to/repo
mapsRoot=path/to/maps
mapsCheckoutTag=HEAD
mapsTagTag=v${buildId}
skipFetch=true
bootclasspath=${java.home}/lib/rt.jar;\${java.home}/lib/jsse.jar;\${java.home}/lib/jce.jar
logExtension=.log
javacDebugInfo=false
javacFailOnError=true
javacVerbose=true
javacSource=1.6
javacTarget=1.6

You should modify the stuff that's in red to suit your local system. In the bootclasspath property, tt's important to include not only rt.jar but jsse.jar and jce.jar, just in case you're doing some security-related things. For some reason Eclipse doesn't pick these up automatically.

Once the configuration file is written, you can run the following command:

java -jar %ECLIPSE_HOME%/plugins/org.eclipse.equinox.launcher_1.1.1.R36x_v20101122_1400.jar -application org.eclipse.ant.core.antRunner -buildfile %ECLIPSE_HOME%/plugins/org.eclipse.pde.build_3.6.2.R36x_20110203/scripts/productBuild/productBuild.xml -Dbuilder=C:/absolute/path/to/builder