# Setting Up A Bugzilla Nightly Build

The Center for Distributed Object Computing has automated daily builds to keep track of the progress made each day for selected software and hardware platforms.

## Unix Instructions

Below are the steps to take to add a platform to the current platforms included in the daily builds. BUILD_NAME should be replaced with the name you want to give the build (e.g., Solaris8_gcc). It can be helpful to embed the OS and the compiler used in BUILD_NAME as in the example in the previous sentence (i.e., Solaris8_gcc => the Solaris 8 operating system and GNU's gcc/g++ compiler).

- Configure CVSROOT as it will be used in the build

          $ cvs checkout ACE_wrappers

          $ cd ACE_wrappers
          $ mkdir build build/BUILD_NAME
          $ ./bin/create_ace_build -a build/BUILD_NAME
          $ mkdir build/BUILD_NAME/auto_compile
          $ touch build/BUILD_NAME/auto_compile/history

- Configure build/BUILD_NAME/ace/config.h. (Solaris 8 is used here as an example.)

          $ echo '#include "ace/config-sunos5.8.h" > build/BUILD_NAME/ace/config.h

- Configure build/BUILD_NAME/include/makeinclude/platform_macros.GNU Solaris 8 and GNU compiler is used here as an example. This example also shows building without debug.

          $ cd build/BUILD_NAME/include/makeinclude
          $ echo 'include $(ACE_ROOT)/include/makeinclude/platform_sunos5_g++.GNU' > platform_macros.GNU
          $ echo 'debug=0' >> platform_macros.GNU

- Setup build script in ~bugzilla/bin. (Copy an existing build script to use as a template. Solaris 8 and GNU compiler is used here as an example.)

          $ su bugzilla
          $ cd ~/bin
          $ cp auto_compile_sunos_gcc272 auto_compile_sunos8_gcc

  Modify the new auto compile file as needed. At a minimum, CHECKOUT and BUILD will need to be modified.
- Create a cron job to run the build. (Decide which machine the build should be done. Add a cron job to bugzilla's crontab.)

          $ ssh -l bugzilla machine_of_choice
          $ crontab -e
          Add cron job to kick off the build every day.

- After the build has been running successfully a few days (not necessarily that there aren't errors or warnings in the compilation or execution) incorporate it into the showlog.cgi script.

          $ cd ~bugzilla/.www-docs/cgi-bin
          $ vi showlog.cgi # to include the build you're making

  Modify the new auto compile file as needed. At a minimum, CHECKOUT and BUILD will need to be modified.

## Win32 Instructions

The Win32 builds use a different set of scripts from the Unix nightly builds. Instructions will be provided here for them at a future date.

## Scoreboard

The scoreboard is the web page created by `ACE_wrappers/bin/nightlybuilds/scoreboard_update.pl`. The main build scoreboard for the DOC Group is located at http://ringil.ece.uci.edu/scoreboard/.

The `scoreboard_update.pl` works by downloading a directory via http, determining the build that has run last, download it, and then parse and create html documents based on it. It requires that the builds name their logs based on the time that the log was created (both `auto_compile` and `prepare_log.pl` do this correctly).

To integrate into the scoreboard, the following steps should be taken:

1. Make the directory containing the log files accessible from the internet (or at least from the machine running the scoreboard, in this case, ringil.ece.uci.edu). This directory must be able to be browsed via the web and should not require a password.
2. Add the build to the appropriate *.lst file in the `ACE_wrappers/bin/nightlybuilds/*.lst`. The main scoreboard uses builds.lst. Each entry looks like the following:

           [BUILD_NAME]
           TYPE = TIMEONLY
           LIST = http://ace.cs.wustl.edu/~bugzilla/auto_compile_logs/build_dir/
           WEB  = http://ace.cs.wustl.edu/~bugzilla/cgi-bin/show_log_dir.cgi?build_dir

   BUILD_NAME, LIST, and WEB should be updated to the appropriate values. TYPE currently needs to be TIMEONLY. LIST refers to the address needed to browse the logs directory. WEB refers to the address used to link to the logs directory (we usually put a url to the show_log_dir.cgi script here).
3. Check in the *.lst file. The scoreboard will automatically update its copy of the list before parsing it.

Last modified: Wed Feb 28 15:32:45 CST 2001