Skip to main content

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.

Jump to: navigation, search

Difference between revisions of "PTP/release engineering"

< PTP
(Versions)
(Build results)
Line 46: Line 46:
 
== Build results ==
 
== Build results ==
  
On completion, a successful build will be located in <code>/home/www/tools/ptp/builds/M.N.S/I.IYYYMMDDHHMM</code>, where <code>M.N.S</code> is the version number of the release, and <code>YYYYMMDDHHMM</code> is the date and time stamp for the build. The location of the output is determined by the <code>copyTo</code> property in the <code>org.eclipse.ptp/build.xml</code> and <code>org.eclipse.ptp.rdt.core.remotejars/build.xml</code> scripts.
+
The nightly and release builds currently put their results in different locations. The results from each intermediate build steps are also available from the hudson build artifacts.
  
The output directory will contain a signed zipped copy of the master update site along with various other files.
+
=== Release builds ===
  
The master update site will be in the form:
+
On completion, a successful build will be located in <code>/home/www/download.eclipse.org/tools/ptp/builds/M.N.S/YYYMMDDHHMM</code>, where <code>M.N.S</code> is the version number of the release, and <code>YYYYMMDDHHMM</code> is the date and time stamp for the build. The build also updates the <code>/home/www/download.eclipse.org/tools/ptp/builds/M.N.S/index.html</code> file to include the new build.
* <code>ptp-master-M.N.S-IYYYYMMDDHHMM.zip</code>
+
  
If the build was not successful, then the partial build will be located in the build directory.
+
=== Nightly builds ===
 +
 
 +
On completion, a successful build will be located in <code>/home/www/download.eclipse.org/tools/ptp/builds/juno/nightly</code>.
  
 
== Modifying the build ==
 
== Modifying the build ==

Revision as of 12:08, 30 January 2012

Overview

PTP uses Hudson for nightly and release builds. Nightly builds will start if a change in the Git repository is detected. Release builds must be manually started (currently).

In order to modify the build configuration, you need to be an authorized user. Please contact Greg, Beth, or Vivian if you need this access.

There are three Hudson jobs associated with each build[1]. The jobs are:

ptp-photran-{nightly|release} 
This job builds the Photran project and generates a zip file containing a p2 repository.
ptp-{nightly|release} 
This job builds the PTP project and generates a zip file containing a p2 repository. The RDT server files and the proxy zip file is also generated.
ptp-master-{nightly|release} 
This job aggregates the Photran and PTP projects together to produce the final repository.

These jobs are linked together so that they run in this order (from top to bottom). E.g. if the ptp-photran-nightly job runs, it will start ptp-nightly when completed, which will in turn start ptp-master-nightly.

All the jobs use Maven to run the build. Maven requires a pom.xml file in each package (plugin or feature) as well as a pom.xml at the top of each project tree. The version numbers of the pom.xml files must be kept in sync with their corresponding feature and plugin version numbers.


  1. This is required because the Hudson Git plugin does not support building from multiple repositories.

Versions

Prior to a new release, the version numbers of various features/plugins must be updated to reflect the version of the build. In general, the version numbers of plugins not listed here should only be changed if the plugin has been modified.

There is now a script that will update the version numbers appropriately as follows:

  1. Obtain a copy of the update_versions script from the org.eclipse.ptp.master.git repository.
  2. Run the command "sh update_versions ptp-version photran-version" where ptp-version is the new version number for PTP, and photran-version is the new version number for Photran, e.g.
    • sh update_versions 3.0.1 5.0.1
    • The command will clone new copies of the photon, ptp, and ptp.master repos and update the versions appropriately
  3. When the command completes, change to fix_ptp_versions and check that the repos have be updated correctly.
  4. Commit and push the changes in each repo in turn using the commands:
    (cd org.eclipse.photran && git commit -m "Update PTP & Photran versions" && git push)
    (cd org.eclipse.ptp && git commit -m "Update PTP & Photran versions" && git push)
    (cd org.eclipse.ptp.master && git commit -m "Update PTP & Photran versions" && git push)
    
  5. Remove the fix_ptp_versions directory

The script should update the version number in the feature.xml for every feature and the pom.xml for every package. There are also a number of plugins that will have their plugin manifest files updated. The main pom.xml files in each repo will also be updated.

Build results

The nightly and release builds currently put their results in different locations. The results from each intermediate build steps are also available from the hudson build artifacts.

Release builds

On completion, a successful build will be located in /home/www/download.eclipse.org/tools/ptp/builds/M.N.S/YYYMMDDHHMM, where M.N.S is the version number of the release, and YYYYMMDDHHMM is the date and time stamp for the build. The build also updates the /home/www/download.eclipse.org/tools/ptp/builds/M.N.S/index.html file to include the new build.

Nightly builds

On completion, a successful build will be located in /home/www/download.eclipse.org/tools/ptp/builds/juno/nightly.

Modifying the build

Changing the build version

In order to change a the build version of PTP, you need to make the following modifications in the appropriate branch:

  • Modify the ptpBranchVersion attribute in org.eclipse.ptp.releng/build.xml (e.g. "3.0.1")
  • Modify the ptpTag and mapVersionTag tags in org.eclipse.ptp/releng/master/build.properties (e.g. "ptp_3_0")
  • Modify the photranTag tag in org.eclipse.ptp/releng/master/build.properties (e.g. "photran_5_0")
  • Modify the serverVersion attribute in org.eclipse.ptp.rdt.core.remotejars/build.xml (e.g. "3.0.1")

Make sure you supply the correct branch tag to the ptpbuild script (e.g. "ptp_3_0") so that the correct version is built.

If all versions don't match correctly, strange things may happen.

Changing the build type

The build.xml script supports four different types of builds:

nightly (default) 
In addition to building, tags the CVS repository with the build version, signs the plugins, runs any tests, then copies the result to the output directory. Note that signing will only work on the Eclipse build server.
build 
Just runs the build.
testbuild 
Runs the build and tests, then copies the result to the output directory.
buildcopy 
Runs the build, and copies the result to the output directory without running any tests.

The build type can be modified by changing the default attribute of the project XML element in the build.xml script.

Changing the version of CDT used to compile RDT

  • Modify the cdtDist property in build.xml to point to the new version.
  • Modify the cdtCoreVersion property in org.eclipse.ptp.rdt.core.remotejars/build.xml to the new value of the org.eclipse.cdt.core plugin. This is generally the same as the CDT distribution I number without the "I", but not always, so it is good to check. e.g. if the CDT distribution is cdt-master-5.0.2.I200902130801.zip, then the cdtCoreVersion should be 5.0.2.200902130801.

Adding a new plugin or feature

For both plugins and features:

  • Add entries in org.eclipse.ptp.releng/maps/ptp.map for the plugin or the feature and all of its plugins
  • Add entries to the tag target element in build.xml to tag the plugin or the feature and its plugins

If a new feature is being added:

  • Add the new feature to the PTP master feature org.eclipse.ptp.master
  • Add the new feature to the update site in org.eclipse.ptp.releng/buildsite.xml

Back to the top