Project

General

Profile

How to build/run RunControl from e2 code

Instructions on how to setup and build RunControl with e2 code on uboonedaq-evb (test stand environment), by Donatella T., Gennadiy L. and Jeremy H.

How to build

Most likely your account will come with a default .bash_profile that sets-up the e6 environment.

To restore the e2 build environment, please delete the symbolic link ~/.bash_profile and recreate your .bash_profile with this content:

# .bash_profile
if [ -f ~/.bashrc ]; then
        . ~/.bashrc
fi
PATH=$PATH:$HOME/bin:/usr/local/WinDriver/wizard
export PATH
LD_LIBRARY_PATH=/usr/local/WinDriver/lib
export LD_LIBRARY_PATH

#ups setup
source /uboone/setup

Then, IF you have not yet checked out the rc code from git, please follow the instructions in this Wiki page:

https://cdcvs.fnal.gov/redmine/projects/uboonedaq/wiki/Setup-uboonedaq-for-development-RC

Follow the instructions up to "make -j32" included.
At this point there will be some errors, due to some mismatched dependencies in the various packages.

Please type "make -j32" again.
This should solve the dependencies and build all packages (ie. no more errors).
(At this point, if you type "make -j32" again, it will show you a nice list of all that has been biult so far).

Now go back to the instructions in the Wiki page and type "make install".

Point 6) in the Wiki page above, tells you to run

. ~development/install/setup

Please check you do have this file. IF NOT please untar /uboonenew/distribution-tarballs/ups-5.1.2-Linux64bit+2.6-2.12.tar.bz2 in your /install directory.
This will get you the setup file.
Then please "source ~development/install/setup"

How to run

Please follow these instructions to setup/launch RunControl.
(I'd recommend to collect these into a setup_rc.sh file)

cd development/build

source /uboone/setup_online.sh
export UBOONEDAQ_HOME_DIR=${HOME}/development
source ../uboonedaq-rc/projectsrc/ups/setup_for_development -d;
cmake -DCMAKE_INSTALL_PREFIX=${UBOONEDAQ_HOME_DIR}/install -DCMAKE_BUILD_TYPE=$CETPKG_TYPE -Dqualifier:STRING=$CETPKG_QUAL $CETPKG_SOURCE;
source ../uboonedaq-rc/projectsrc/configs/development_setup_RC_env.sh
source ../install/setup
## v5_01_00 is available ONLY on ubdaq-prod-evb
#setup uboonedaq v5_01_00 -q e2:debug
## so ,use v5_02_00 on uboonedaq-evb
setup uboonedaq v5_02_00 -q e2:debug

cd ~;

Jeremy suggested to define some very useful aliases to semplify the commands, such as:

alias startdaq='bash ${UBOONEDAQ_HOME_DIR}/uboonedaq-rc/projectsrc/configs/start_RC_system.sh'
alias stopdaq='bash ${UBOONEDAQ_HOME_DIR}/uboonedaq-rc/projectsrc/configs/stop_RC_system.sh'
alias startrc='bash ${UBOONEDAQ_HOME_DIR}/uboonedaq-rc/projectsrc/configs/DAQOperationsTools/bin/startRunControl.sh'
alias stoprc='bash ${UBOONEDAQ_HOME_DIR}/uboonedaq-rc/projectsrc/configs/DAQOperationsTools/bin/stopRunControl.sh'

You can add then to your .bash_profile file or to the setup_rc.sh file.

Next time you login, you just do "source setup_rc.sh" and you'll be ready to launch RunControl, DAQApplicationMAnager and ResourceMAnager.