Install

Create a couple of new directories:

$ mkdir calice_soft
$ cd calice_soft
$ mkdir build
$ mkdir install

Inside DESY

Get the repositories, e.g.

$ git clone /group/hcal/calice_soft/git_repo/calice_userlib
$ git clone /group/hcal/calice_soft/git_repo/calice_reco
$ git clone /group/hcal/calice_soft/git_repo/calice_sim
$ git clone /group/hcal/calice_soft/git_repo/calice_whatevertheremaybe

You can check your git branch settings by

$ cd calice_userlib    (or any other)
$ git branch
$ git branch -r

The first branch command lists the local branches, while the second displays all remotely available ones. The branch that is in use presently is marked by a '*'. If this branch is not the one that you actually intend to use, you can create a new branch and check it out by

$ git checkout -b <new> <reference>

<new> is the name you want to give your branch and <reference> is the remote reference to it. Once you have set the right branch, you can check for recent changes in it and apply them by simply using the "pull" command:

$ git pull

If you have AFS access

$ git clone /afs/desy.de/group/flc/hcal/calice_soft/git_repo/calice_userlib
...

This is the recommended way.

Via CERN lxplus

If you come from !DESY, but have a CERN lxplus account, you can do s.th. like:

$ git clone ssh://<username>@lxplus.cern.ch/afs/desy.de/group/flc/hcal/calice_soft/git_repo/calice_userlib

(Thanks to Guilherme Lima for this hint.)

Use this method if your institute does not support AFS, but you have a CERN account.

Via www

If none of the above solutions fits your needs go to either http://flc-hgf.desy.de/e13/e133 and follow the instructions or http://www-flc.desy.de/hcal/git, if you want to download an archive.

Next steps

Get calicebuild-v01-03-04.cmake and at the bottom change the paths according to your setup.

Now we can start with calice_userlib.

$ cd build
$ mkdir calice_userlib
$ cd calice_userlib
$ cmake -C path-to-calicebuild-v01-03.cmake ../../calice_userlib
$ make
$ make install

After the cmake -C you should get s.th. like:

loading initial cache file ../../calicebuild-v01-03.cmake
-- Check for working C compiler: /usr/bin/gcc
-- Check for working C compiler: /usr/bin/gcc -- works
-- Check size of void*
-- Check size of void* - done
-- Check for working CXX compiler: /usr/bin/c++
-- Check for working CXX compiler: /usr/bin/c++ -- works
-- Check for LCIO: /afs/desy.de/group/it/ilcsoft/v01-03/lcio/v01-09 -- works
-- Check for Marlin: /afs/desy.de/group/it/ilcsoft/v01-03/Marlin/v00-09-10 -- works
-- Check for LCCD: /afs/desy.de/group/it/ilcsoft/v01-03/lccd/v00-03-06 -- works
-- Check for CondDBMySQL: /afs/desy.de/group/it/ilcsoft/v01-03/CondDBMySQL/CondDBMySQL_ILC-0-5-10 -- works
-- Check for LCCD: /afs/desy.de/group/it/ilcsoft/v01-03/lccd/v00-03-06 -- works
-- Check for CondDBMySQL: /afs/desy.de/group/it/ilcsoft/v01-03/CondDBMySQL/CondDBMySQL_ILC-0-5-10 -- works
-- /data/nwattime/calice_test/install/lib
--
--
-- -------------------------------------------------------------------------------
-- BUILD_SHARED_LIBS                       = ON
-- CMAKE_INSTALL_PREFIX                    = /data/nwattime/calice_test/install
-- CMAKE_BUILD_TYPE                        = RelWithDebInfo
-- BUILD_WITH_BOUNDARY_CHECK               = OFF
-- BUILD_WITH_VALUE_CHECK                  = OFF
-- BUILD_WITH_CONV_DEBUG                   = OFF
-- BUILD_WITH_RECO_DEBUG                   = OFF
-- BUILD_WITH_DEBUG_CONDDB_WRITER          = OFF
-- BUILD_WITH_USE_LCCD                     = ON
-- -- LCCD_HOME                            = /afs/desy.de/group/it/ilcsoft/v01-03/lccd/v00-03-06
-- -- Marlin_HOME                          = /afs/desy.de/group/it/ilcsoft/v01-03/Marlin/v00-09-10
-- BUILD_EXAMPLES                          = OFF
-- BUILD_WITH_DEPRECATED                   = OFF
-- BUILD_WITH_TRIGGER_HANDLER_IS_SINGLETON = ON
-- LCIO_HOME                               = /afs/desy.de/group/it/ilcsoft/v01-03/lcio/v01-09
-- LCCD_HOME                               = /afs/desy.de/group/it/ilcsoft/v01-03/lccd/v00-03-06
-- Marlin_HOME                             = /afs/desy.de/group/it/ilcsoft/v01-03/Marlin/v00-09-10
-- Change a value with: cmake -D<Variable>=<Value>
-- -------------------------------------------------------------------------------
--
-- Configuring done
-- Generating done
-- Build files have been written to: /data/nwattime/calice_test/build/calice_userlib

After that we can tell calicebuild-v01-03.cmake where to search for CALICE_USERLIBConfig.cmake. This should be similar to

SET( CALICE_USERLIB_DIR "/something/calice_soft/install/cmake"
     CACHE PATH "Path to calice_userlib" FORCE )

All the *Config.cmake go to this directory.

Go to your build directory

$ cd build
$ mkdir calice_reco
$ cd calice_reco
$ cmake -C path-to-calicebuild-v01-03.cmake ../../calice_reco
$ make
$ make install

Now you have to tell Marlin to use the new libraries. Create a myMarlin-v01-03 in your ~/bin.

#
# myMarlin-v01-03 -- script to start Marlin with your libraries
#

# we want to access dcache directly
export LD_PRELOAD=/opt/products/lib/libpdcap.so

# the path of the libraries, fancy zsh feature, use marlin_dll as array 
# and MARLIN_DLL as colon seperated scalar
export -TU MARLIN_DLL marlin_dll

marlin_dll=(/something/install/lib/libuserlib.so
            /something/install/lib/libraw2calohit.so)

# start Marlin
/afs/desy.de/group/it/ilcsoft/v01-03/Marlin/v00-09-10/bin/Marlin "$@"

Make the script executable

$ cd ~/bin/
$ chmod +x myMarlin-v01-03

Try it

$ myMarlin-v01-03 -l > defaults.steer
$ less defaults.steer

The first lines should be:

<!-- Loading shared library : /myPath/lib/libuserlib.so -->
<!-- Loading shared library : /myPath/lib/libraw2calohit.so -->
DBConnectionMgr::getDBConnection( PathToDB)
DBInterface::init: connected to database calice using folder: /expert_cd_calice/CALDAQ_RunLocation
  ##########################################
  #                                        #
  #     Example steering file for marlin   #
  #                                        #
  ##########################################

You can see, that your new libraries have been loaded.

Proceed with all the packages you want in the same way, for example calice_sim.

HCAL Calice Quickstart (last edited 2009-06-16 18:32:15 by localhost)