How to use calice software out-of-the-box

In priniciple the one-touch-installation is replaced by the flcini command:

$ flcini calice_pro_test

calice_pro_test refers to the most recent development version which can do whatever it likes to do. Thus you are sure, that you get the best that we have at the moment.
There are two other versions you can choose instead:
calice_pro refers to the latest HCAL release. Stuff that will then be included in the next CALICE software release.
calice without suffix is the latest stable and official version of the CALICE software released. See HCAL Repos_and_Builds.

After that you can execute caliceMarlin with your steering file whereever you are:

/somewhere/ $ caliceMarlin steering-file.steer

If you refer to caliceMarlin you mean, that you use the version you have initialized with flcini before.

Please do NOT use flcini in case you have you have your own RootTreeWriter and calice_hh_proc packages, because by default, when you use flcini, the libraries for the RootTreeWriter and for the calice_hh_proc from the afs installation are loaded, and you'll get a conflict!

How to add your own processors

Download the calice_torso package:

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

There is already a README which explains almost everything, so please read it!

REMARK: as of 2008-10-23 the following steps require a modification to the file calicebuild.cmake. This is due to changing versions and paths. A version that works (today 2008-10-23) is available here: calicebuild.cmake

REMARK to the REMARK: There are more up-to-date cmake files for the various packages in the central software folder:

/afs/desy.de/group/flc/hcal/calice_soft/pro_test/<package>.cmake_deps

You should use them instead of calicebuild.cmake.

Finished reading? Great, let's do the first steps together:

$ mkdir build
$ cd build
$ flcini cmake
$ cmake -C ../calicebuild.cmake ../
loading initial cache file ../calicebuild.cmake
-- Check for Marlin: /afs/desy.de/group/flc/hcal/calice_soft/ilcsoft/Marlin/v00-09-08 -- works
-- Check for LCIO: /afs/desy.de/group/it/ilcsoft/v01-01/lcio/v01-08-03 -- works
-- Check for LCCD: /afs/desy.de/group/it/ilcsoft/v01-01/lccd/v00-03-06 -- works
-- Check for ROOT: /afs/desy.de/group/it/ilcsoft/v01-01/root/5.08.00 -- works
--
-- -------------------------------------------------------------
-- CMAKE_INSTALL_PREFIX               = /tmp/test/calice_torso
-- CMAKE_BUILD_TYPE                   = RelWithDebInfo
-- USE_Marlin                         = ON
-- USE_LCIO                           = ON
-- USE_LCCD                           = ON
-- USE_ROOT                           = ON
-- USE_CALICE_USERLIB                 = ON
-- USE_RAW2CALOHIT                    = ON
-- USE_RAW2LCIO                       = OFF
-- Change a value with: cmake -D<Variable>=<Value>
-- -------------------------------------------------------------
-- Configuring done
-- Generating done
-- Build files have been written to: /tmp/test/calice_torso/build

Compile and install:

$ make install
[100%] Building CXX object src/CMakeFiles/Private.dir/HelloWorldProcessor.o
Linking CXX shared library ../lib/libPrivate.so
[100%] Built target Private
Linking CXX shared library CMakeFiles/CMakeRelink.dir/libPrivate.so
Install the project...
-- Install configuration: "RelWithDebInfo"
-- Installing /tmp/test/calice_torso/lib/libPrivate.so.1.0.0

Installing new processor

Now we can use Marlin with our own library, which consists only of the HelloWorldProcessor.

Because the only thing we did was adding a new library, we can use the installed calice_reco (libraw2calohit), for example. Let's see where it is:

$ flcini caliceSoft
$ cat `which caliceMarlin`
export MARLIN_DLL=/afs/desy.de/group/flc/hcal/calice_soft/stable/lib/libraw2calohit.so.4.6.1:
                  /afs/desy.de/group/flc/hcal/calice_soft/stable/lib/libraw2lcio.so.4.6.1
#exec /afs/desy.de/group/it/ilcsoft/v01-01/Marlin/v00-09-08/bin/Marlin $@

Now we add our own library:

$ export MARLIN_DLL=/tmp/test/calice_torso/lib/libPrivate.so.1.0.0:
                    /afs/desy.de/group/flc/hcal/calice_soft/stable/lib/libraw2calohit.so.4.6.1:
                    /afs/desy.de/group/flc/hcal/calice_soft/stable/lib/libraw2lcio.so.4.6.1

Let's see if it worked, use the path to Marlin from the cat which caliceMarlin.

$ /afs/desy.de/group/it/ilcsoft/v01-01/Marlin/v00-09-08/bin/Marlin -l | grep -A2 MyHello
.begin MyHelloWorldProcessor
ProcessorType HelloWorldProcessor
#---Prints 'Hello World' for every event

Of course you should install your library to a nice place and adjust your PATH to run Marlin easily.

A new way exists which doesn't include hacking around. Simply do an

export ADD_MARLIN_DLL=/tmp/test/calice_torso/lib/libPrivate.so.1.0.0

and caliceMarlin will load the additional library for you.

Using ROOT in the 'official' Framework

It turned out that our installation of the official CALICE software only work correctly, if at runtime $ROOTSYS (and in some special cases also the LD_LIBRARY_PATH) points to the exact version of ROOT which was used to build the software.

Please run

flcini ILC_ROOT

and link your programs against

/afs/desy.de/group/it/ilcsoft/root

The reason for this is that ROOT loads some libraries at runtime using its own mechanism, which ignores the UNIX library version information. As result you might get segmentation faults, which might appear to be unrelated to ROOT. I noticed that in newer ROOT versions there is some ROOT internal symbol versioning.

HCAL Calice How to use the new software (last edited 2010-01-13 09:25:18 by lucaci)