Tinderbox Setup

From Apache OpenOffice Wiki
Revision as of 04:50, 23 December 2005 by Vq (Talk | contribs)

Jump to: navigation, search

Disclaimer! I tried the tinderbox sripts that are described on this page only with W32-tcsh so far. They are to be considered of beta quality only. Patches are very much appreciated.


What is tinderbox

In essence tinderbox is a perl script that processes mail, and turns it into HTML. It expects to be mailed build logs from separate and de-coupled build machines. Tinderbox has a few elaborations over the most simple 'status' web-page, inasmuch that it integrates with bonsai - to correlate builds against commits, and it has some nice built in error-parsers to allow huge build logs to be condensed to just a few (possible) tricky sections.

Setting up a build slave

To do this, you need to be able to build OO.o already; if you can't do this start here: Building.

The framework that is described in the following sections can be used to build "new" and "Ready-for-QA" CWSs and MWSs of the 680er codeline. The source is fetched from cvs.

See this webpage for a list of the currently accepted tags. You will find the build logs (providing there are any) when you click on the corresponding tag.

Requirements

This directory contains a mininimal framework to build OOo CWSs and MWSs and sent the reports to the tinderbox at go-oo.org.

You need to get the following files from that directory:

tin-main.pl
tinprep.sh
tinbuild.sh
tinget.pl
tinsend.pm

In addition to these files you need to install the Sender.pm Perl module from CPAN. See the CPAN link <http://go-ooo.org/cpan.html> for details about getting this module.

Configuration

A few files have to be adapted to match your local setup. Changes only have to be done in areas marked with:

"# -- End of Things to tweak --"
  • tin-main.pl
    These variables need to be adapted (Follow the example in the source):
    $tinsend::FROMADDRESS
    $tinsend::SMTPAUTH
    $tinsend::SMTPSERVER
    $tinsend::SMTPAUTHID
    $tinsend::SMTPAUTHPW
    
  • tinbuild.sh
    Set the options to configure your OOo build.
  • tinprep.sh
    OOo needs some things prepared before it can be build. Things like that go into this file.

Start the tinderbox build

The build is then started with:

./tin-main.pl "OOoW32(opti)" /cygdrive/d/w1/SRC680_m146 SRC680_m146 co send

The first parameter sets the name the build identifies itself, the second gives the target directory the source is build in, the third sets which CWS/MWS is used (see here for allowed values), the fourth how the source is obtained/treated (checked out from cvs in this case) and the last one says that the buildlog is send to the tinderbox. The parameters are discussed in detail later in this document.

Documentation

The following part describes the used scripts and useful parameters. (The markup needs a brush-up.)

tin-main.pl
Syntax (all five parameters are needed):
tin-main.pl buildstring src_path ws {co|up|cont|clean} {send|nosend}
  buildstring - Name that will appear in the tinderbox
  src_path    - Pointing to source to be used
  ws          - Which workspace shall be build. It accepts CWSs names (from the
                list in <http://go-oo.org/tinderbox/tags/tag-list>) or all MWSs
                starting with ???680_m*.
  co|up|cont|clean - Tells the script what to do with src_path. Fresh checkout,
                update a current repo (this also deletes modified/extra files),
                do nothing, just start/continue with current repo, and clean
                removes all wntmsci10.pro before rebuilding.
  send|nosend - send the logfile to the tinderbox (or not)

The main program that starts the build, captures the logfile and sends it to
the tinderbox.

Example: ./tin-main.pl "OOoW32(opti)" /cygdrive/d/w1/SRC680_m146 SRC680_m146 co send


tinsend.pl
This module handles sending of mails with attachments. This was necessary
because the windows build logs are easily 30MB or more and in our early
setups this was just to much to be handled by some SMTP servers and also
for go-oo.org. See some documentation inline in that file.


tinget.pl
Syntax (all four parameters are needed):
tinget.pl ws buildlog src_path {co|up|cont|clean}
  ws          - See tinder-main.pl.
  buildlog    - logfile name (this is send to the tinderbox)
  src_path    - See tinder-main.pl.
  {co|up|cont|clean} - See tinder-main.pl.

This script does the orkspace (src_path) handling.


tinbuild.sh
Syntax:
tinbuild.sh ws buildsys buildlog src_path
  Parameter see tinder-main.pl, buildsys includes {cyg|4nt} but can also
  handle several special cases.

The actual build script that starts the build and captures the logfile.


tinprep.sh
Syntax:
tinprep.sh src_path

Prepare the workspace for the build
Personal tools