Mirrors CERN QMUL |
ATLAS Level 1 Calorimeter Trigger Software | |||||||||||||||||||||
L1Calo Software | Using CMT | |||||||||||||||||||||
![]()
|
IntroductionCMT is a code management tool which has now been adopted as the ATLAS standard.This page addresses some issues of using CMT within the L1Calo software project. InstallationCMT can be obtained from here. You need the source distribution plus the Linux binary version (or you can build it yourself from the source). After unpacking the tar files, you need to run themgr/INSTALL script.
For my convenience (Ive tried several versions) I put
all the above steps into a script
Having downloaded (or built) a version (eg v1r18p20041201)
of CMT in some directory, you need to source the setup script.
It is convenient to do this in your source somedir/CMT/v1r18p20041201/mgr/setup.sh Working modelSince much of our software is based on the Online software, it seems sensible to adopt their working model, rather than develop a different one of our own.The normal CMT approach is to keep all the compiled binaries in architecture specific directories within the package directory structure. This is useful while developing a package. In addition to this, the Online working model defines an installation area where all the binaries and C++ headers of all packages can be installed together. This can then be the basis of a binary release.
CMT defines a minimal required directory structure. Beneath
the package directory, is a (now optional) subdirectory for each tagged
version of the package (though the Online group recommend
only dealing with one version at a time!). Within the tag
subdirectory there must be a "
CMT normally expects to find source code in "
However the ATLAS convention for accessing C++ header files does
require you to keep them all in a single directory named after
the package.
With this convention the header files are used with
" So the typical directory structure (without the optional version directory) might look like: workarea/<package>/cmt /<package> (C++ header files) /src (C++ source for libraries) /bin (C++ source for applications) /test (C++ test programs) /jsrc (Java source for jar files)CMT puts all the object files, dependency files, automatically generated makefiles as well as the libraries and executable applications into a single "binary branch" (ie directory) which by default is named after the architecture and operating system, eg " i386_Linux ".
However the Online group define another
set of CMT binary tags (not the same as CVS tags) which are
combinations of architecture, OS, compiler and other flags,
eg "i686-slc3-gcc323-dbg " and "i686-slc3-gcc323-opt ".
These must be defined before running any CMT
commands. If you normally work on a single architecture, you
can put a suitable command into your .login or
.profile file:
CMTCONFIG="i686-slc3-gcc323-dbg"; export CMTCONFIG Creating a new CMT packageTo create a new CMT package, ie one which is not already in CVS, you need to create a new CMT directory structure and then populate it with subdirectories following the directory scheme above, eg:cd workarea/LVL1/l1calo cmt -without_ver create myPackage myPackage-00-00-00 cd myPackage mkdir myPackage bin test # CMT already created cmt and src directoriesAfter that create the requirements file, run cmt config
and build the packages as above.
The package can the be entered into CVS as a new Working with CMTOnce a package is CMT compliant, you can use some of the scripts in ourscripts
package to checkout packages
in CMT style directories.
Also look at our web page on how to set up the L1Calo software. CMT Requirements FileThe syntax is described in the CMT manual (html, pdf). The Online working model contains an annotated example of one of their packages. Some further hints or examples would be useful. I will add something here when I get that far...But in the meantime, there is a little detail on some of the features provided in our use of CMT which are defined in our L1CaloPolicy package. You can also look at example requirements files from our existing packages. Follow the links below then click on the "Rev." link for the requirements file:
Last updated on 19-Jan-2006 by Murrough Landon |