Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.
Difference between revisions of "JWT Automatic Build"
(→What we have) |
(→JWT build minimal Eclipse base) |
||
Line 49: | Line 49: | ||
=== JWT build minimal Eclipse base === | === JWT build minimal Eclipse base === | ||
− | ''' | + | In order for the build and automated testing to be working as fast as possible, it is necessary to maintain a build base (in ''/shared/technology/jwt/base'' on build.eclipse.org), that contains only the projects that are necessary to build and test JWT, and to ensure that these project are built for for the build server you are using. |
+ | |||
+ | ==== Creating the base ==== | ||
+ | |||
+ | To create a build base, you'll need to expand the following projects in the directory you want to use ase the eclipse base: | ||
+ | * Eclipse platform linux/ppc/gtk => ''~/downloads/eclipse/downloads/[buildId]/eclipse-platform-[version]-linux-gtk-ppc.tar.gz'' | ||
+ | * Eclipse PDE => ''~/downloads/eclipse/downloads/[buildId]/eclipse-PDE-[version].zip'' | ||
+ | * Eclipse JDT => ''~/downloads/eclipse/downloads/[buildId]/eclipse-JDT-[version].zip'' | ||
+ | * EMF Runtime => ''~/downloads/modeling/emf/emf/downloads/drops/[version]/[buildId]/emf-runtime-[buildId].zip'' | ||
+ | * GEF Runtime => ''~/downloads/tools/gef/downloads/drops/[version]/[buildId]/GEF-runtime-[buildId].zip'' | ||
+ | |||
+ | Choosing the version of each project: | ||
+ | * Currently, JWT build on Eclipse server uses the latest version that contains a Maintenance or Release build (ie buildId starting with R or M) | ||
+ | * However, we could discuss about trying to build usng stable or milestone builds, to ensure the compatibility with the latest versions of projects. But this would require much more work until we succeed to automate the creation of the base with the latest drops... | ||
== How to use it == | == How to use it == |
Revision as of 08:41, 6 January 2009
Contents
Automatic build of JWT Features and Plugins
Helpful resources
- General information about building
- Article from Markus Barchfeld about automatic building
- Sample project
What we did
Pre-requirements
- First, we downloaded CVS support for the command line: [CVS]
- Afterwards, we downloaded PDE Releng:
cvs -d :pserver:anonymous@dev.eclipse.org:/cvsroot/eclipse export -r HEAD org.eclipse.releng.eclipsebuilder
- We set some system variables, e.g. the ECLIPSE_HOME-variable:
set ECLIPSE_HOME=C:\Programme\Eclipse //adapt to your Eclipse home directory
- And also configured the Build target directory:
set BUILD_HOME=C:\Build\New //adapt to your Build directory
Startup the build process
- Generate a build.xml from the feature using right-click, PDE Build -> Generate Ant Script (this creates a build.xml in the feature directory)
- Go to the directory of the feature: cd ...\jwt-we-feature
- Execute:
java -cp %ECLIPSE_HOME%\plugins\org.eclipse.equinox.launcher_1.0.101.R34x_v20080819.jar org.eclipse.core.launcher.Main -application org.eclipse.ant.core.antRunner -buildfile build.xml -Dcomponent=sdk.examples -Dconfigs="*,*,*" -Dbaseos=win32 -Dbasews=win32 -Dbasearch=x86 -Djavacfailonerror=true -Dpde.build.scripts=%ECLIPSE_HOME%/plugins/org.eclipse.pde.build_3.4.1.R34x_v20080805/scripts -DbaseLocation=%ECLIPSE_HOME% -DbuildDirectory=&BUILD_HOME%
- This generates the JAR-file of the feature.
What we have
JWT build minimal Eclipse base
In order for the build and automated testing to be working as fast as possible, it is necessary to maintain a build base (in /shared/technology/jwt/base on build.eclipse.org), that contains only the projects that are necessary to build and test JWT, and to ensure that these project are built for for the build server you are using.
Creating the base
To create a build base, you'll need to expand the following projects in the directory you want to use ase the eclipse base:
- Eclipse platform linux/ppc/gtk => ~/downloads/eclipse/downloads/[buildId]/eclipse-platform-[version]-linux-gtk-ppc.tar.gz
- Eclipse PDE => ~/downloads/eclipse/downloads/[buildId]/eclipse-PDE-[version].zip
- Eclipse JDT => ~/downloads/eclipse/downloads/[buildId]/eclipse-JDT-[version].zip
- EMF Runtime => ~/downloads/modeling/emf/emf/downloads/drops/[version]/[buildId]/emf-runtime-[buildId].zip
- GEF Runtime => ~/downloads/tools/gef/downloads/drops/[version]/[buildId]/GEF-runtime-[buildId].zip
Choosing the version of each project:
- Currently, JWT build on Eclipse server uses the latest version that contains a Maintenance or Release build (ie buildId starting with R or M)
- However, we could discuss about trying to build usng stable or milestone builds, to ensure the compatibility with the latest versions of projects. But this would require much more work until we succeed to automate the creation of the base with the latest drops...
How to use it
Update sites organisation
First, as it is the case in most of "one feature" projects (such as GEF), JWT now has 3 update sites:
- http://download.eclipse.org/technology/jwt/update-site is the update-site that contains the current release of JWT
- http://download.eclipse.org/technology/jwt/integration-update-site is the update-site the could contain any development or nightly build of JWT. Contents of this update-site should only be used by JWT contributors for testing.
- http://download.eclipse.org/technology/jwt/stable-update-site is the update-site for stable development build, and also for Galileo milestones
Start a build for build.eclipse.org
Anyone who has access to build.eclipse.org can now start a build of cvs HEAD by typing from JWT home folder ./build.sh [buildType] where build type is I (default), S or R, respectively for integration, stable or release build.
This script will start the whole build process and update the update-site for the specified build type.
Start a build on your local machine
If you want to build locally JWT, simply checkout the org.eclipse.jwt/releng CVS module and write a script that starts the build with your local configuration (please do not modify build.sh or build.properties, that are build.eclipse.org files). See build.mistria.openwide.sh for example.
Continuous integration
TODO Note that the PDE build process supports unit testing. I've read about several Eclipse projects that used a continuous integration tool (such as cruise, continuum or hudson) to monitor their builds and test results. I'll try to choose if one of these solutions is fine for JWT.
Releasing Policy
When releasing JWT, here are the steps to follow:
- Tag the feature and all plugins included into the release with tag R{releaseVersion} (for example R0.5.0)
- Build on build.eclipse.org the feature to release (./build.sh R). The update site is automatically updated.
- Increment the feature version number (See Version Numbering)
- Increment all plugins versions that will be modified in next release)
- Create a buzz about this release!
Adding new plugons to the JWT release
TODO