-

Overview

LHCb scripts are stored below $LHCBSCRIPTS (/afs/cern.ch/lhcb/scripts) with 4 sub-directories: shell, cern, win32, python.

  • $LHCBSCRIPTS/cern - contains cern-centric scripts, cannot be used outside.
  • $LHCBSCRIPTS/shell - contains scripts which could be of general use in LHCb ( may be with some customization)
  • $LHCBSCRIPTS/win32 - contains *.bat scripts to be used on Windows
  • $LHCBSCRIPTS/python - contains python scripts
  • $LHCBSCRIPTS - contains softlinks to some shell/ and cern/ scripts and some wrapper scripts to python scripts.

Some of the scripts are saved on CVS in $CVSROOT/scripts.

Some of the scripts are saved in platform-dependent tar files for exportation (mkscriptstar).

  • Following a cvs commit
    • tar files should be rebuilt
    • win32 DFS repository should be updated:
      • G:\Experiments\lhcb\scripts
      • cvs update

Shell scripts

  • lhcbsetup.csh, lhcbsetup.sh
    • lhcbsetup.(c)sh is run at login time to set some CERN LHCb environment variables.
    • all LHCb scripts and applications assume LHCb environment is set
  • CMT.csh, CMT.sh
    • CMT.(c)sh is run at login time: source $LHCBSCRIPTS/CMT.(c)sh
      • set $CMTROOT, $CMTCONFIG, $CMTDEB, $CMTPATH, $LHCBPROJECTPATH
      • set all release_area: LCG_release_area, Gaudi_release_area, LHCb_release_area, etc....
      • set aliases such as <Project>Env, setenv<Project>, cmt<Project>, run<Project>
      • set $PATH and $LD_LIBRARY_PATH when necessary for not default compiler
      • set ROOTSYS and $LD_LIBRARY_PATH if not defined to please make
      • to compile and run slc3 on lxplus : lbcmt gcc323
  • ExtCMT.csh, ExtCMT.sh
    • is equivalent to CMT.(c)sh for LOCAL installation.
    • is distributed with any project tar ball.
    • it requires the setting of $MYSITEROOT and $CMTSITE=LOCAL beforehand
    • $MYSITEROOT is the full path (no symlink) of the LOCAL installation.
    • it is available in $MYSITEROOT/scripts
  • ProjectEnv.csh, ProjectEnv.sh
    • source ProjectEnv.(c)sh <project> <version> to set CMTPATH for projects built without_installarea
  • setenvProject.csh, setenvProject.sh
    • source setenvProject.(c)sh <project> <version> to set CMTPROJECTPATH and user working area for projects built with_installarea
    • if CMTPROJECTPATH is not set : it sets it
    • if $User_release_area/<project>_<version> does not exist : it creates it
    • cd $User_release_area/<project>_<version>
  • SetupProject.csh, SetupProject.sh
    • execute python $LHCBPYTHON/SetupProject.py $*
    • SetupProject [options] <project> [<version>|--ask] will make a source setup.(c)sh in the first <project>Sys/<version>/cmt directory found on the CMTPROJECTPATH
  • Lbglimpse
    • get all occurences of a string in a project and its dependencies
      • Lbglimpse <a_string> <Project> <version>
  • mkscriptstar
    • build a tar file, stored on $LHCBTAR/scripts, for Linux or Win32 with a selection of usefull scripts
      • mkscriptstar Win32
      • mkscriptstar Linux
  • mkexternaltar
    • build CMT_<version> and OpenScientist_<version> binary tar file for different platforms.
      • mkexternaltar CMT <version> <linux|win32|mac>
      • mkexternaltar OpenScientist <version> <binary>

Win32 scripts

  • lhcbsetup.bat
  • ExtCMT.bat
  • ProjectEnv.bat, <project>Env.bat
  • setenvProject.bat
  • SetupProject.bat
  • getpack.bat
  • usedProjects.bat
  • lcgspi_local.bat
  • localsetup.bat
  • setcmt.bat
  • make.bat
  • which.bat
  • copy-Win2afs.bat
  • mkproject.bat

Python scripts

  • install_project.py
    • install a project with all its dependencies on `pwd` path:
      • cd <somewhere>
      • setenv MYSITEROOT `pwd`
      • setenv CMTCONFIG "one of the LHCb binary"
      • python install_project.py -p <project> -v <version> -b
  • LHCb_config.py
    • is imported by all mkxxxx.py scripts to describe and configure LHCb projects.
    • it contains project names, project volume sizes, application names, etc...
  • vol_for_releases.py
    • is called by mkproject to create a volume for a project release
  • mkLHCbtar.py
    • is called by mkproject to create tar files for various platform.
    • must be run to create tar files of just release of DBASE, PARAM packages.
  • mkproject.py
    • used to make a full release of a project.
  • mkLCGCMTtar.py
    • must be run to create a LCGCMT tarfile which contains all external (external and lcg) packages used by a given Gaudi version for a given platform.
      • cd $LHCBTAR/source
      • mkLCGCMTtar -n GAUDI_<version> -b <binary>
      • check the mkLCGCMTtar.log file and the existence of LCGCMT_<vers>_<binary>.tar.gz
  • mkGENSERtar.py
    • was used to create a GENSER binary tar file for up to Gauss DC06 version.
    • it is now obsolete: for Gauss version > v30r* mkMCGentar.py should be used instead.
  • mkMCGentar.py
    • should be used to create a binary tar file containing all generators used by a given Gauss version
      • cd $LHCBTAR/source
      • mkMCGentar -n GAUSS_<version> -b <binary>
      • check the mkMCGentar.log file and the existence of GENSER_<vers>_<binary>.tar.gz
  • copy-Win2afs.py
    • should be run on win32 to cmt config and cmt build vsnet a project residing on afs and to copy the InstallArea and package binary directories on afs
      • cd F:\LCG_LHCbSoft\lhcb\&ltPROJECT>\<PROJECT>_<version>
      • copy-Win2afs
  • lcg-mirror-externals
    • SPI script to copy all external packages referenced by a LCGCMT version from afs to local win32
  • usedProjects
    • get all dependencies of all projects available on $CMTPROJECTPATH
      • setenv CMTPROJECTPATH $LHCBPROJECTPATH
      • usedProjects
  • SetupProject
    • set the project environment
      • SetupProject <Project> <version>

Cern scripts

-- FlorenceRanjard - 28 Feb 2007

Edit | Attach | Watch | Print version | History: r23 < r22 < r21 < r20 < r19 | Backlinks | Raw View | WYSIWYG | More topic actions
Topic revision: r23 - 2008-11-25 - MarcoCattaneo
 
    • Cern Search Icon Cern Search
    • TWiki Search Icon TWiki Search
    • Google Search Icon Google Search

    LHCb All webs login

This site is powered by the TWiki collaboration platform Powered by PerlCopyright & 2008-2019 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback