From b5f13f8655df6ec202a9a4ca491775935a3c60ef Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Mon, 19 Sep 2022 12:56:04 +0200 Subject: [PATCH 1/5] Fix standalone build script --- build_standalone.sh | 216 +++++++++++++++++++------------------------- 1 file changed, 91 insertions(+), 125 deletions(-) diff --git a/build_standalone.sh b/build_standalone.sh index 2c8cce668..65c52c5cf 100755 --- a/build_standalone.sh +++ b/build_standalone.sh @@ -9,8 +9,8 @@ # Author : M.Frank # #=============================================================================== -export BINARY_TAG=x86_64-centos7-gcc11-dbg; -export LCG_VIEW=/cvmfs/sft.cern.ch/lcg/views/LCG_101/${BINARY_TAG}; +BINARY_TAG=x86_64-centos7-gcc11-dbg; +LCG_VIEW=/cvmfs/sft.cern.ch/lcg/views/LCG_101/${BINARY_TAG}; export RDKAFKA_DIR=/group/online/dataflow/cmtuser/libraries/kafka/rdkafka-gcc-11.1.0-opt; #=============================================================================== @@ -24,74 +24,6 @@ do_echo() echo $*; $*; } -do_cmake() -{ - PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o t:s:i:v: --longoptions type:,source:,install:,view: -- "[cmake step]" $*) - VALID_ARGUMENTS=$? - if [ "$VALID_ARGUMENTS" != "0" ]; then - echo "====> Invalid arguments to cmake step"; - exit 1; - fi; - build_type=; - source_dir=; - install_dir=; - lcg_view=; - eval set -- "$PARSED_ARGUMENTS"; - while : - do - case "${1}" in - -t | --type) build_type=${2}; shift 2 ;; - -s | --source) source_dir=${2}; shift 2 ;; - -i | --install) install_dir=${2}; shift 2 ;; - -v | --view) lcg_view=${2}; shift 2 ;; - # -- means the end of the arguments; drop this, and break out of the while loop - --) shift; break;; - # If invalid options were passed, then getopt should have reported an error, - # which we checked as VALID_ARGUMENTS when getopt was called... - *) echo "====> Unexpected option: $1 - this should not happen." - exit 1; shift; break;; - esac; - done; - do_echo cmake -DCMAKE_INSTALL_PREFIX="${install_dir}" \ - -DCMAKE_BUILD_TYPE=${build_type} \ - -DSUPPORT_GAUDI=OFF \ - -DLCG_VIEW=${lcg_view} \ - ${source_dir} - if [ $? -ne 0 ]; then - echo "ERROR: Failed cmake step!"; - exit 1; - fi; -} -#=============================================================================== -# Build project -# -# Author : M.Frank -# -#=============================================================================== -do_build() -{ - curr_dir=`pwd`; - top=`dirname ${curr_dir}`; - make $*; - if [ $? -ne 0 ]; then - echo "ERROR: Failed make step!"; - exit 1; - fi; -} -#=============================================================================== -# Install project -# -# Author : M.Frank -# -#=============================================================================== -do_install() -{ - make install $*; - if [ $? -ne 0 ]; then - echo "ERROR: Failed install step!"; - exit 1; - fi; -} #=============================================================================== # Print help # @@ -101,27 +33,35 @@ do_install() usage() { echo " do_make -opt [-opt]" - echo " -t --type <build_type> Supply build type Debug0|Debug|Release. Default: Debug0"; - echo " -s --source <source directory> Source directory for cmake"; - echo " Default: `pwd`"; - echo " CMakeLists.txt required!"; - echo " -b --build <build directory> Build directory for cmake"; - echo " Default: `pwd`/dataflow_build.${binary_tag}"; - echo " -i --install <install directory> Installation directory for cmake"; - echo " Default: `pwd`/dataflow_install.${binary_tag}"; - echo " -v --view <path to LCG view> Path to the LCG view directory."; - echo " Setup file for LCG view required!"; - echo " -T --tag <tag-name> Binary tag to be used. Default: ${BINARY_TAG}"; - echo " Setup file for LCG view required!"; - echo " -c --cmake-only Execute only cmake step"; - echo " -B --build-only Only build: no cmake, no install"; - echo " -I --install-only Only install: no cmake, no build"; - echo " -p --parallel <number> Number of threads for parallel build (make -j <number>)"; + echo " -t --type <build_type> Supply build type Debug0|Debug|Release. Default: Debug0"; + echo " -s --source <source directory> Source directory for cmake"; + echo " Default: `pwd`"; + echo " CMakeLists.txt required!"; + echo " -b --build-dir <build directory> Build directory for cmake"; + echo " Default: `pwd`/dataflow_build.${binary_tag}"; + echo " -i --install-dir <install directory> Installation directory for cmake"; + echo " Default: `pwd`/dataflow_install.${binary_tag}"; + echo " -v --view <path to LCG view> Path to the LCG view directory."; + echo " Setup file for LCG view required!"; + echo " -T --tag <tag-name> Binary tag to be used. Default: ${BINARY_TAG}"; + echo " Setup file for LCG view required!"; + echo " -c --cmake Execute only cmake step"; + echo " -B --build Only build: no cmake, no install"; + echo " -I --install Only install: no cmake, no build"; + echo " -p --parallel <number> Number of threads for parallel build (make -j <number>)"; + echo ""; + echo ""; + echo " Example:"; + echo ""; + echo " cd /group/online/dataflow/cmtuser/ONLINE/ONLINE_v7r19"; + echo " . /cvmfs/lhcb.cern.ch/lib/lcg/releases/LCG_101/gcc/11.1.0/x86_64-centos7/setup.sh"; + echo " ./build_standalone.sh -t Debug0 --tag x86_64-centos7-gcc11-dbg --view /cvmfs/lhcb.cern.ch/lib/lcg/releases/LCG_101 -c -B -I"; + echo ""; exit 1; } # # -PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o hcBIT:t:s:b:i:v:p: --longoptions help,cmake-only,build-only,install-only,tag:,type:,source:,build:,install:,view:,parallel: -- "[build_dataflow]" $*) +PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o hcBIT:t:s:b:i:v:p: --longoptions help,cmake,build,install,tag:,type:,source:,build-dir:,install-dir:,view:,parallel: -- "[build_dataflow]" $*) VALID_ARGUMENTS=$? if [ "$VALID_ARGUMENTS" != "0" ]; then echo "====> Invalid arguments to cmake step"; @@ -134,8 +74,8 @@ source_dir=; install_dir=; lcg_view=${LCG_VIEW}; binary_tag=; -cmake_only=; -build_only=; +execute_cmake=; +execute_build=; install_only=; parallel="-j 12"; # @@ -144,14 +84,14 @@ while : do case "${1}" in -t | --type) build_type=${2}; shift 2 ;; - -b | --build) build_dir=${2}; shift 2 ;; -s | --source) source_dir=${2}; shift 2 ;; - -i | --install) install_dir=${2}; shift 2 ;; + -b | --build-dir) build_dir=${2}; shift 2 ;; + -i | --install-dir) install_dir=${2}; shift 2 ;; -v | --view) lcg_view=${2}; shift 2 ;; -T | --tag) binary_tag=${2}; shift 2 ;; - -c | --cmake-only) cmake_only=YES; shift ;; - -B | --build-only) build_only=YES; shift ;; - -I | --install-only) install_only=YES; shift ;; + -c | --cmake) execute_cmake=YES; shift ;; + -B | --build) execute_build=YES; shift ;; + -I | --install) install_only=YES; shift ;; -p | --parallel) parallel="-j ${2}"; shift 2 ;; -h | --help) usage; shift ;; # -- means the end of the arguments; drop this, and break out of the while loop @@ -169,25 +109,25 @@ if test -z "${binary_tag}"; then binary_tag=${BINARY_TAG}; fi; -if test -z "${cmake_only}"; then - echo "" > /dev/null; -elif test -z "${lcg_view}"; then - echo "====> [do_cmake] Missing argument --view [path to LCG view]"; - exit 1; -elif [ ! -f ${lcg_view}/setup.sh ]; then - echo "====> [do_cmake] LCG View path is wrong: no setup found."; -# exit 1; -fi; - if test -z "${source_dir}"; then source_dir=`pwd`; fi; if [ ! -f ${source_dir}/CMakeLists.txt ]; then - echo "====> [do_cmake] Invalid source directory: ${source_dir}"; - echo "====> [do_cmake] No CMakeLists.txt file present."; + echo "====> [build_standalone] Invalid source directory: ${source_dir}"; + echo "====> [build_standalone] No CMakeLists.txt file present."; exit 1; fi; +if test -z "${execute_cmake}"; then + echo "" > /dev/null; +elif test -z "${lcg_view}"; then + echo "====> [build_standalone] Missing argument --view [path to LCG view]"; + exit 1; +elif [ ! -d ${lcg_view} ]; then + echo "====> [build_standalone] LCG View path is wrong: no directory found."; +# exit 1; +fi; + if test -z "${build_dir}"; then build_dir=${source_dir}/dataflow_build.${binary_tag}; fi; @@ -195,15 +135,24 @@ if test -z "${install_dir}"; then install_dir=${source_dir}/dataflow_install.${binary_tag}; fi; -if test -n "${cmake_only}"; then - source ${lcg_view}/setup.sh; -elif test -z "${cmake_only}" -a -z "${build_only}" -a -z "${install_only}"; then - source ${lcg_view}/setup.sh; -elif test -f ${install_dir}/bin/thisonline.sh; then +echo "Using LCG view from ${lcg_view} Binary tag: ${binary_tag} cmake: `which cmake`"; +if [ -f ${install_dir}/bin/thisonline.sh ]; then source ${install_dir}/bin/thisonline.sh; +elif [ -f "${lcg_view}/setup.sh" ]; then + source ${lcg_view}/setup.sh; +elif [ -d "${lcg_view}" ]; then + #echo "Using LCG view from ${lcg_view} Binary tag: ${binary_tag} cmake: `which cmake`"; + export PATH=${lcg_view}/CMake/3.20.0/${binary_tag}/bin:${PATH} + lcg_platform=`echo "${binary_tag}" | tr "-" " " | awk '{ print $1"-"$2 }'`; + lcg_comp=`echo "${binary_tag}" | tr "-" " " | awk '{ print $3 }'`; + lcg_dbg=`echo "${binary_tag}" | tr "-" " " | awk '{ print $4 }'`; + echo "====> [build_standalone] Using LCG view from ${lcg_view} Binary tag: ${binary_tag}"; + echo "====> [build_standalone] cmake: `which cmake` platform: ${lcg_platform} compiler: ${lcg_comp}"; + #echo . ${lcg_view}/${lcg_comp}/11.1.0/${lcg_platform}/setup.sh + #. ${lcg_view}/gcc/11.1.0/${lcg_platform}/setup.sh else - echo "====> Do you really know what you want ?"; -# usage; + echo "====> [build_standalone] Do you really know what you want ?"; + usage; fi; # # @@ -223,21 +172,38 @@ echo "++ ==============================================================="; # # A bit a queer logic, but I do not know how to do better: # -if test -z "${build_only}" -a -z "${install_only}"; then - do_cmake --type ${build_type} --source "${source_dir}" --install "${install_dir}" --view "${LCG_VIEW}"; -elif test -n "${cmake_only}"; then - do_cmake --type ${build_type} --source "${source_dir}" --install "${install_dir}" --view "${LCG_VIEW}"; +if test -n "${execute_cmake}"; then + do_echo cmake -DCMAKE_INSTALL_PREFIX="${install_dir}" \ + -DCMAKE_BUILD_TYPE=${build_type} \ + -DSUPPORT_GAUDI=OFF \ + -DLCG_VIEW=${lcg_view} \ + -DBINARY_TAG=${binary_tag} \ + ${source_dir} + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed cmake step!"; + if test -n "echo `which c++ | grep /usr`"; then + echo "====> [build_standalone] Are you sure you have the proper compiler setup ?"; + fi; + exit 1; + fi; fi; # -if test -z "${cmake_only}" -a -z "${install_only}"; then - do_build ${parallel}; -elif test -n "${build_only}"; then - do_build ${parallel}; +if test -n "${execute_build}"; then + do_echo make ${parallel}; + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed make step!"; + if test -n "echo `which c++ | grep /usr`"; then + echo "====> [build_standalone] Are you sure you have the proper compiler setup ?"; + fi; + exit 1; + fi; fi; # -if test -z "${cmake_only}" -a -z "${build_only}"; then - do_install ${parallel}; -elif test -n "${install_only}"; then - do_install ${parallel}; +if test -n "${install_only}"; then + do_echo make install -j 10; + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed install step!"; + exit 1; + fi; fi; -- GitLab From b368c62e47f73f342d0f3cb5a49e69805918059b Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Mon, 19 Sep 2022 14:22:49 +0200 Subject: [PATCH 2/5] Allow to build event builder only in standalone build --- CMakeLists.txt | 21 ++++++++++++--------- build_standalone.sh | 12 +++++++++--- 2 files changed, 21 insertions(+), 12 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 788f54a49..a5c4fa36b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -18,11 +18,12 @@ ENABLE_LANGUAGE(CXX) ENABLE_LANGUAGE(C) SET(Online_DIR ${CMAKE_SOURCE_DIR} CACHE STRING "Online directory") -option(SUPPORT_GAUDI "Build Online dataflow stuff and GaudiOnline components" ON) -option(HAVE_EB "Include event builder library in build" ON) -option(PLUGIN_SOURCES "[Standalone build] Path to the Gaudi Plugin manager sources" OFF) -option(LCG_VIEW "[Standalone build] Path to LCG View" OFF) -option(BINARY_TAG "[Standalone build] Binary tag of packages used from LCG View" OFF) +option(SUPPORT_GAUDI "Build Online dataflow stuff and GaudiOnline components" ON) +option(HAVE_EB "Include event builder library in build" ON) +option(PLUGIN_SOURCES "[Standalone build] Path to the Gaudi Plugin manager sources" OFF) +option(LCG_VIEW "[Standalone build] Path to LCG View" OFF) +option(BINARY_TAG "[Standalone build] Binary tag of packages used from LCG View" OFF) +option(EVENTBUILDER_ONLY "[Standalone build] Build eventbuilder and dependencies only" OFF) list(PREPEND CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake) @@ -113,15 +114,16 @@ if ( 1 ) add_subdirectory(Online/Parsers) add_subdirectory(Online/Dataflow) add_subdirectory(Online/DataflowExample) - if ( HAVE_EB ) + if ( HAVE_EB OR EVENTBUILDER_ONLY ) add_subdirectory(Online/EventBuilding) endif() # - # Other online monitoring, logger and controller stuff - add_subdirectory(Online/UPI) - add_subdirectory(Online/ROMon) add_subdirectory(Online/RPC) add_subdirectory(Online/RPCServer) + add_subdirectory(Online/ROMon) + # Other online monitoring, logger and controller stuff + if ( NOT EVENTBUILDER_ONLY ) + add_subdirectory(Online/UPI) add_subdirectory(Online/GauchoServer) add_subdirectory(Online/DefHLTUtils) add_subdirectory(Online/IPMI) @@ -133,6 +135,7 @@ if ( 1 ) add_subdirectory(Online/SmiController) add_subdirectory(Online/TestBeam) add_subdirectory(Online/Checkpointing) + endif() endif() # ======================================================================= # Standalone build ends here: diff --git a/build_standalone.sh b/build_standalone.sh index 65c52c5cf..e82fb0d19 100755 --- a/build_standalone.sh +++ b/build_standalone.sh @@ -49,6 +49,7 @@ usage() echo " -B --build Only build: no cmake, no install"; echo " -I --install Only install: no cmake, no build"; echo " -p --parallel <number> Number of threads for parallel build (make -j <number>)"; + echo " -e --ebonly Build event builder only"; echo ""; echo ""; echo " Example:"; @@ -61,7 +62,7 @@ usage() } # # -PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o hcBIT:t:s:b:i:v:p: --longoptions help,cmake,build,install,tag:,type:,source:,build-dir:,install-dir:,view:,parallel: -- "[build_dataflow]" $*) +PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o hcBIeT:t:s:b:i:v:p: --longoptions help,cmake,build,install,ebonly,tag:,type:,source:,build-dir:,install-dir:,view:,parallel: -- "[build_dataflow]" $*) VALID_ARGUMENTS=$? if [ "$VALID_ARGUMENTS" != "0" ]; then echo "====> Invalid arguments to cmake step"; @@ -77,6 +78,7 @@ binary_tag=; execute_cmake=; execute_build=; install_only=; +eb_only=OFF; parallel="-j 12"; # eval set -- "$PARSED_ARGUMENTS"; @@ -89,10 +91,11 @@ do -i | --install-dir) install_dir=${2}; shift 2 ;; -v | --view) lcg_view=${2}; shift 2 ;; -T | --tag) binary_tag=${2}; shift 2 ;; - -c | --cmake) execute_cmake=YES; shift ;; - -B | --build) execute_build=YES; shift ;; + -c | --cmake) execute_cmake=YES; shift ;; + -B | --build) execute_build=YES; shift ;; -I | --install) install_only=YES; shift ;; -p | --parallel) parallel="-j ${2}"; shift 2 ;; + -e | --ebonly) eb_only=ON; shift ;; -h | --help) usage; shift ;; # -- means the end of the arguments; drop this, and break out of the while loop --) shift; break;; @@ -134,6 +137,8 @@ fi; if test -z "${install_dir}"; then install_dir=${source_dir}/dataflow_install.${binary_tag}; fi; +build_dir=`realpath ${build_dir}`; +install_dir=`realpath ${install_dir}`; echo "Using LCG view from ${lcg_view} Binary tag: ${binary_tag} cmake: `which cmake`"; if [ -f ${install_dir}/bin/thisonline.sh ]; then @@ -178,6 +183,7 @@ if test -n "${execute_cmake}"; then -DSUPPORT_GAUDI=OFF \ -DLCG_VIEW=${lcg_view} \ -DBINARY_TAG=${binary_tag} \ + -DEVENTBUILDER_ONLY=${eb_only} \ ${source_dir} if [ $? -ne 0 ]; then echo "====> [build_standalone] ERROR: Failed cmake step!"; -- GitLab From c4b4442e649501ca00cc4e1d0ed0eaf46b8666d4 Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Mon, 19 Sep 2022 15:11:59 +0200 Subject: [PATCH 3/5] Allow to build event builder only in standalone build --- build_standalone.sh | 109 +++++++++++++++++++++++++++++++++----------- 1 file changed, 82 insertions(+), 27 deletions(-) diff --git a/build_standalone.sh b/build_standalone.sh index e82fb0d19..bef8448f3 100755 --- a/build_standalone.sh +++ b/build_standalone.sh @@ -9,10 +9,13 @@ # Author : M.Frank # #=============================================================================== -BINARY_TAG=x86_64-centos7-gcc11-dbg; -LCG_VIEW=/cvmfs/sft.cern.ch/lcg/views/LCG_101/${BINARY_TAG}; -export RDKAFKA_DIR=/group/online/dataflow/cmtuser/libraries/kafka/rdkafka-gcc-11.1.0-opt; - +build_parse_this() { + SOURCE=${1} + # get param to "." + thisroot=$(dirname ${SOURCE}) + THIS=$(cd ${thisroot} > /dev/null;pwd); export THIS; + unset SOURCE thisroot +} #=============================================================================== # Configure project # @@ -60,7 +63,18 @@ usage() echo ""; exit 1; } +#=============================================================================== # +#=============================================================================== +build_parse_this $0; +if [ ! -f ${THIS}/build_standalone.sh ]; then + echo "+++ Wrong working directory! [${THIS}]"; + exit 1; +fi; +# +BINARY_TAG=; ## x86_64-centos7-gcc11-dbg; +LCG_VIEW=; ##/cvmfs/sft.cern.ch/lcg/views/LCG_101/${BINARY_TAG}; +export RDKAFKA_DIR=/group/online/dataflow/cmtuser/libraries/kafka/rdkafka-gcc-11.1.0-opt; # PARSED_ARGUMENTS=$(getopt -a -n do_cmake -o hcBIeT:t:s:b:i:v:p: --longoptions help,cmake,build,install,ebonly,tag:,type:,source:,build-dir:,install-dir:,view:,parallel: -- "[build_dataflow]" $*) VALID_ARGUMENTS=$? @@ -68,6 +82,9 @@ if [ "$VALID_ARGUMENTS" != "0" ]; then echo "====> Invalid arguments to cmake step"; usage; fi; +# +# +# echo "++ PARSED_ARGUMENTS: $PARSED_ARGUMENTS"; build_type=; build_dir=; @@ -75,9 +92,9 @@ source_dir=; install_dir=; lcg_view=${LCG_VIEW}; binary_tag=; -execute_cmake=; -execute_build=; -install_only=; +exec_cmake=; +exec_build=; +exec_install=; eb_only=OFF; parallel="-j 12"; # @@ -91,9 +108,9 @@ do -i | --install-dir) install_dir=${2}; shift 2 ;; -v | --view) lcg_view=${2}; shift 2 ;; -T | --tag) binary_tag=${2}; shift 2 ;; - -c | --cmake) execute_cmake=YES; shift ;; - -B | --build) execute_build=YES; shift ;; - -I | --install) install_only=YES; shift ;; + -c | --cmake) exec_cmake=YES; shift ;; + -B | --build) exec_build=YES; shift ;; + -I | --install) exec_install=YES; shift ;; -p | --parallel) parallel="-j ${2}"; shift 2 ;; -e | --ebonly) eb_only=ON; shift ;; -h | --help) usage; shift ;; @@ -111,17 +128,26 @@ done; if test -z "${binary_tag}"; then binary_tag=${BINARY_TAG}; fi; - if test -z "${source_dir}"; then source_dir=`pwd`; fi; +# +# OK. Now check pre-conditions +# +# +if [ -z "${binary_tag}" ]; then + # This should never happen: if no binary tag, no LCG view! + echo "====> [${build_script}] No valid binary tag supplied."; + exit 1; +fi; +# if [ ! -f ${source_dir}/CMakeLists.txt ]; then echo "====> [build_standalone] Invalid source directory: ${source_dir}"; echo "====> [build_standalone] No CMakeLists.txt file present."; exit 1; fi; -if test -z "${execute_cmake}"; then +if test -z "${exec_cmake}"; then echo "" > /dev/null; elif test -z "${lcg_view}"; then echo "====> [build_standalone] Missing argument --view [path to LCG view]"; @@ -137,14 +163,18 @@ fi; if test -z "${install_dir}"; then install_dir=${source_dir}/dataflow_install.${binary_tag}; fi; +# +lcg_view=`realpath ${lcg_view}`; build_dir=`realpath ${build_dir}`; +source_dir=`realpath ${source_dir}`; install_dir=`realpath ${install_dir}`; - +# echo "Using LCG view from ${lcg_view} Binary tag: ${binary_tag} cmake: `which cmake`"; -if [ -f ${install_dir}/bin/thisonline.sh ]; then +if test -f ${install_dir}/bin/thisonline.sh -a -z "${exec_cmake}"; then source ${install_dir}/bin/thisonline.sh; elif [ -f "${lcg_view}/setup.sh" ]; then source ${lcg_view}/setup.sh; + CMAKE_OPTS="-DONLINE_ROOT_SYS=${ROOTSYS} -DPLUGIN_SOURCES=${lcg_view}"; elif [ -d "${lcg_view}" ]; then #echo "Using LCG view from ${lcg_view} Binary tag: ${binary_tag} cmake: `which cmake`"; export PATH=${lcg_view}/CMake/3.20.0/${binary_tag}/bin:${PATH} @@ -155,15 +185,13 @@ elif [ -d "${lcg_view}" ]; then echo "====> [build_standalone] cmake: `which cmake` platform: ${lcg_platform} compiler: ${lcg_comp}"; #echo . ${lcg_view}/${lcg_comp}/11.1.0/${lcg_platform}/setup.sh #. ${lcg_view}/gcc/11.1.0/${lcg_platform}/setup.sh + CMAKE_OPTS="-DBINARY_TAG=${binary_tag} -DPLUGIN_SOURCES=/cvmfs/lhcb.cern.ch/lib/lhcb/GAUDI/GAUDI_v36r7/GaudiPluginService"; else echo "====> [build_standalone] Do you really know what you want ?"; usage; fi; # # -mkdir -p ${build_dir}; -mkdir -p ${install_dir}; -cd ${build_dir}; # echo "++ ==============================================================="; echo "++ Configure cmake for building ${build_type} "; @@ -177,16 +205,24 @@ echo "++ ==============================================================="; # # A bit a queer logic, but I do not know how to do better: # -if test -n "${execute_cmake}"; then +if [ -z "${exec_cmake}" ]; then + echo "++ No cmake step required --> Skipped."; +else + mkdir -p ${build_dir}; + cd ${build_dir}; + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed to change build directory: ${build_dir}."; + echo "====> [build_standalone] ERROR: Did you miss out something ?"; + exit 1; + fi; do_echo cmake -DCMAKE_INSTALL_PREFIX="${install_dir}" \ - -DCMAKE_BUILD_TYPE=${build_type} \ - -DSUPPORT_GAUDI=OFF \ - -DLCG_VIEW=${lcg_view} \ - -DBINARY_TAG=${binary_tag} \ - -DEVENTBUILDER_ONLY=${eb_only} \ + -DCMAKE_BUILD_TYPE=${build_type} \ + -DSUPPORT_GAUDI=OFF ${CMAKE_OPTS} \ + -DLCG_VIEW=${lcg_view} \ + -DEVENTBUILDER_ONLY=${eb_only} \ ${source_dir} if [ $? -ne 0 ]; then - echo "====> [build_standalone] ERROR: Failed cmake step!"; + echo "====> [build_standalone] ERROR: Failed cmake step!"; if test -n "echo `which c++ | grep /usr`"; then echo "====> [build_standalone] Are you sure you have the proper compiler setup ?"; fi; @@ -194,10 +230,16 @@ if test -n "${execute_cmake}"; then fi; fi; # -if test -n "${execute_build}"; then +if test -n "${exec_build}"; then + cd ${build_dir}; + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed to change build directory: ${build_dir}."; + echo "====> [build_standalone] ERROR: Did you miss out the cmake step ?"; + exit 1; + fi; do_echo make ${parallel}; if [ $? -ne 0 ]; then - echo "====> [build_standalone] ERROR: Failed make step!"; + echo "====> [build_standalone] ERROR: Failed make step!"; if test -n "echo `which c++ | grep /usr`"; then echo "====> [build_standalone] Are you sure you have the proper compiler setup ?"; fi; @@ -205,7 +247,20 @@ if test -n "${execute_build}"; then fi; fi; # -if test -n "${install_only}"; then +if test -n "${exec_install}"; then + mkdir -p ${install_dir}; + if [ $? -ne 0 ]; then + echo "====> [build_standalone] ERROR: Failed to create the install directory: ${install_dir}."; + exit 1; + fi; + if [ ! -f ${build_dir}/bin/thisonline.sh ]; then + echo "====> [build_standalone] ERROR: cmake step was apparently not successful --> redo ?"; + exit 1; + fi; + echo "====> [build_standalone] PATH: $PATH"; + echo "Executing build/installation step..."; + source ${build_dir}/bin/thisonline.sh; + echo "====> [build_standalone] PATH: $PATH"; do_echo make install -j 10; if [ $? -ne 0 ]; then echo "====> [build_standalone] ERROR: Failed install step!"; -- GitLab From dddbc9097dc0943b7f0fa97456d2feb31c6a7f0a Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Tue, 20 Sep 2022 09:07:38 +0200 Subject: [PATCH 4/5] Fix Dataflow UI component and add fixes to kafka logger --- CMakeLists.txt | 49 ++++++++++++++++-------- Online/FarmConfig/job/BU.sh | 4 +- Online/FarmConfig/job/RU.sh | 4 +- Online/ROLogger/kafka/KafkaConsumer.cpp | 3 ++ Online/ROLogger/kafka/KafkaProducer.cpp | 3 ++ Online/ROLogger/kafka/LogServer.cpp | 3 ++ Online/ROLogger/kafka/LogServer.h | 3 +- Online/ROLogger/kafka/OutputListener.cpp | 10 ++--- Online/ROLogger/kafka/OutputLogger.cpp | 2 +- Online/ROMon/rpc/PyRPC.cpp | 4 +- Online/ROMon/src/HltSummaryDisplay.cpp | 4 +- Online/ROMon/src/NodeStatsCollector.cpp | 4 +- Online/dim/CMakeLists.txt | 2 +- build_standalone.sh | 8 +++- cmake/OnlineStandalone.cmake | 37 ++++++++++++++++-- cmake/find_package_path.py | 20 ++++++++++ cmake/thisonline.sh.in | 11 ++++-- 17 files changed, 126 insertions(+), 45 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index a5c4fa36b..249aa244a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -63,6 +63,9 @@ else() message ( STATUS "+++===========================================================================================+++" ) include(OnlineStandalone) # + if ( NOT BINARY_TAG ) + get_filename_component(BINARY_TAG "${LCG_VIEW}" NAME) + endif() set(ONLINE_PREREQUISITES) online_check_prerequisites(ONLINE_PREREQUISITES) if ( NOT "${ONLINE_PREREQUISITES}" STREQUAL "OK" ) @@ -71,11 +74,23 @@ else() endif() # online_set_compiler_flags() + if ( EXISTS ${PLUGIN_SOURCES}/src/PluginServiceV1.cpp ) + # Import plugin manager from Gaudi + online_locate_dependencies() + online_build_pluginmanager(${PLUGIN_SOURCES}) + else() + # Import plugin manager from the LCG View + set(_view "${LCG_VIEW}") + set(ONLINE_LCG_VIEW_SETUP "${_view}/setup.sh") + set(CMAKE_PREFIX_PATH "${_view}:${_view}/lib:${_view}/lib64:${CMAKE_PREFIX_PATH}") + online_env(SET ONLINE_RUNTIME_PATH "${_view}/bin") + online_env(SET ONLINE_LIBRARY_PATH "${_view}/lib:${_view}/lib64") + online_import_pluginmanager(${LCG_VIEW}) + endif() online_locate_dependencies() # ======================================================================= include(OnlineDependencies) online_print_setup() - online_build_pluginmanager(${PLUGIN_SOURCES}) endif() # # ======================================================================= @@ -109,6 +124,9 @@ if ( 1 ) # # Dataflow components add_subdirectory(Online/HTTP) + add_subdirectory(Online/RPC) + add_subdirectory(Online/RPCServer) + add_subdirectory(Online/ROMon) add_subdirectory(Online/sqldb) add_subdirectory(Online/Storage) add_subdirectory(Online/Parsers) @@ -118,23 +136,22 @@ if ( 1 ) add_subdirectory(Online/EventBuilding) endif() # - add_subdirectory(Online/RPC) - add_subdirectory(Online/RPCServer) - add_subdirectory(Online/ROMon) # Other online monitoring, logger and controller stuff if ( NOT EVENTBUILDER_ONLY ) - add_subdirectory(Online/UPI) - add_subdirectory(Online/GauchoServer) - add_subdirectory(Online/DefHLTUtils) - add_subdirectory(Online/IPMI) - add_subdirectory(Online/MBMDump) - add_subdirectory(Online/PcSrv) - add_subdirectory(Online/PyDIM) - add_subdirectory(Online/ROLogger) - add_subdirectory(Online/smixx) - add_subdirectory(Online/SmiController) - add_subdirectory(Online/TestBeam) - add_subdirectory(Online/Checkpointing) + add_subdirectory(Online/UPI) + add_subdirectory(Online/GauchoServer) + add_subdirectory(Online/DefHLTUtils) + add_subdirectory(Online/IPMI) + add_subdirectory(Online/MBMDump) + add_subdirectory(Online/PcSrv) + add_subdirectory(Online/PyDIM) + add_subdirectory(Online/ROLogger) + # SMI controller + add_subdirectory(Online/smixx) + add_subdirectory(Online/SmiController) + # Debug utilities + add_subdirectory(Online/TestBeam) + add_subdirectory(Online/Checkpointing) endif() endif() # ======================================================================= diff --git a/Online/FarmConfig/job/BU.sh b/Online/FarmConfig/job/BU.sh index 03ab7c719..77592344d 100755 --- a/Online/FarmConfig/job/BU.sh +++ b/Online/FarmConfig/job/BU.sh @@ -13,8 +13,8 @@ unset PYTHONPATH; unset PYTHONHOME; eval `/usr/bin/python2 -c "import os;s=os.environ['UTGID'];print 'export BU_OPTIONS='+s[s.find('BU'):]+'.opts'"`; # . /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64-centos7-gcc9-opt.vars; -. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-do0.vars; -#. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-opt.vars; +#. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-do0.vars; +. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-opt.vars; # . /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.${CMTCONFIG}.vars; cd ${FARMCONFIGROOT}/job; # diff --git a/Online/FarmConfig/job/RU.sh b/Online/FarmConfig/job/RU.sh index b95211bc3..ec85e7845 100755 --- a/Online/FarmConfig/job/RU.sh +++ b/Online/FarmConfig/job/RU.sh @@ -9,8 +9,8 @@ # # ========================================================================= # -#. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-opt.vars; -. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-do0.vars; +. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-opt.vars; +#. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64_v2-centos7-gcc10-do0.vars; # . /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.x86_64-centos7-gcc9-opt.vars; #. /group/online/dataflow/EventBuilder/EventBuilderRelease/setup.${CMTCONFIG}.vars; cd ${EVENTBUILDINGROOT}/options; diff --git a/Online/ROLogger/kafka/KafkaConsumer.cpp b/Online/ROLogger/kafka/KafkaConsumer.cpp index ff41b72d7..9bfe0ccb0 100644 --- a/Online/ROLogger/kafka/KafkaConsumer.cpp +++ b/Online/ROLogger/kafka/KafkaConsumer.cpp @@ -22,6 +22,9 @@ /// Framework include files #include "LogServer.h" +/// Kafka include file +#include "rdkafka.h" /* for Kafka driver */ + /// C/C++ include files #include <map> #include <memory> diff --git a/Online/ROLogger/kafka/KafkaProducer.cpp b/Online/ROLogger/kafka/KafkaProducer.cpp index cf34041f9..bfc92117b 100644 --- a/Online/ROLogger/kafka/KafkaProducer.cpp +++ b/Online/ROLogger/kafka/KafkaProducer.cpp @@ -23,6 +23,9 @@ #include "KafkaProducer.h" #include <RTL/rtl.h> +/// Kafka include file +#include "rdkafka.h" /* for Kafka driver */ + /// C/C++ include files #include <vector> #include <cstring> diff --git a/Online/ROLogger/kafka/LogServer.cpp b/Online/ROLogger/kafka/LogServer.cpp index c15e8269f..a57e1eb62 100644 --- a/Online/ROLogger/kafka/LogServer.cpp +++ b/Online/ROLogger/kafka/LogServer.cpp @@ -25,6 +25,9 @@ #include <RTL/rtl.h> #include <dim/dis.h> +/// Kafka include file +#include "rdkafka.h" /* for Kafka driver */ + /// C/C++ include files #include <cstdio> #include <cstring> diff --git a/Online/ROLogger/kafka/LogServer.h b/Online/ROLogger/kafka/LogServer.h index 3a3d1852c..67330866b 100644 --- a/Online/ROLogger/kafka/LogServer.h +++ b/Online/ROLogger/kafka/LogServer.h @@ -27,8 +27,7 @@ #include <memory> #include <list> -/// Kafka include file -#include "rdkafka.h" /* for Kafka driver */ +typedef struct rd_kafka_message_s rd_kafka_message_t; /// kafka namespace declaration namespace kafka { diff --git a/Online/ROLogger/kafka/OutputListener.cpp b/Online/ROLogger/kafka/OutputListener.cpp index 3c7d73bec..b220211e5 100644 --- a/Online/ROLogger/kafka/OutputListener.cpp +++ b/Online/ROLogger/kafka/OutputListener.cpp @@ -162,9 +162,9 @@ void OutputListener::handle_payload(const char* /* topic */, //printf("@%16lX: %.*s: %.*s\n", m->offset, (int)m->key_len, (char*)m->key, (int)m->len, (char*)m->payload); char* time_stamp = payload + 15; - int match = *(long*)payload == PAYLOAD_MATCH; + int pay_match = *(long*)payload == PAYLOAD_MATCH; - if ( match ) { + if ( pay_match ) { std::string raw_msg; *(time_stamp+10) = ' '; *(time_stamp+19) = 0; @@ -231,14 +231,14 @@ void OutputListener::handle_payload(const char* /* topic */, } } if ( !message_match.empty() ) { - bool match = false; + bool match_msg = false; for ( const auto& m : message_match ) { if ( std::regex_match(message, m) ) { - match = true; + match_msg = true; break; } } - if ( !match ) return; + if ( !match_msg ) return; } /// If match criteria are empty, the message is accepted. /// If not, we want to have an AND logic. diff --git a/Online/ROLogger/kafka/OutputLogger.cpp b/Online/ROLogger/kafka/OutputLogger.cpp index 57260e193..443ef33d5 100644 --- a/Online/ROLogger/kafka/OutputLogger.cpp +++ b/Online/ROLogger/kafka/OutputLogger.cpp @@ -94,7 +94,7 @@ extern "C" int run_output_logger (int argc, char **argv) { graphics::consolesize(&rows,&cols); graphics::bg_black(); graphics::white(); - for(size_t i=0;i<rows;++i) ::fprintf(stdout,"\n"); + for(size_t j=0;j<rows;++j) ::fprintf(stdout,"\n"); have_colors = true; break; case 'g': // Kafka group-id diff --git a/Online/ROMon/rpc/PyRPC.cpp b/Online/ROMon/rpc/PyRPC.cpp index 28cc5416b..86d232fbd 100755 --- a/Online/ROMon/rpc/PyRPC.cpp +++ b/Online/ROMon/rpc/PyRPC.cpp @@ -310,8 +310,8 @@ Arg& Arg::assign(const Data& d) { return *this; } -Arg& Arg::load(const string& v, const string& tag) { - Item it(v,tag); +Arg& Arg::load(const string& val, const string& tag) { + Item it(val,tag); string item = it.value(); if ( !item.empty() ) { if ( debug() ) cout << endl << "ITEM:" << item << endl << "End_ITEM" << endl; diff --git a/Online/ROMon/src/HltSummaryDisplay.cpp b/Online/ROMon/src/HltSummaryDisplay.cpp index 1b6c1e9f2..01795d656 100644 --- a/Online/ROMon/src/HltSummaryDisplay.cpp +++ b/Online/ROMon/src/HltSummaryDisplay.cpp @@ -113,8 +113,8 @@ void HltSummaryDisplay::update(const void* ptr) { int run = (*ri).first; int files = (*ri).second; run_files[run] += files; - map<int,set<string> >::iterator i = run_nodes.find(run); - if ( i == run_nodes.end() ) { + map<int,set<string> >::iterator runit = run_nodes.find(run); + if ( runit == run_nodes.end() ) { run_nodes[run] = set<string>(); } } diff --git a/Online/ROMon/src/NodeStatsCollector.cpp b/Online/ROMon/src/NodeStatsCollector.cpp index cf0370298..dcb24eb09 100644 --- a/Online/ROMon/src/NodeStatsCollector.cpp +++ b/Online/ROMon/src/NodeStatsCollector.cpp @@ -277,8 +277,8 @@ int NodeStatsCollector::monitorHLT(char* buffer, const std::vector<std::string>& } while ( (entry=::readdir(dir)) != 0 ) { int run=0, date; - int ret = ::sscanf(entry->d_name,"Run_%010d_%8d-",&run,&date); - if ( ret == 2 ) { + int status = ::sscanf(entry->d_name,"Run_%010d_%8d-",&run,&date); + if ( status == 2 ) { map<int,int>::iterator i=files.find(run); if ( i==files.end() ) files[run]=1; else ++((*i).second); diff --git a/Online/dim/CMakeLists.txt b/Online/dim/CMakeLists.txt index f820d5a23..01e4c6641 100644 --- a/Online/dim/CMakeLists.txt +++ b/Online/dim/CMakeLists.txt @@ -97,7 +97,7 @@ endmacro() dim_exe_basic(did.exe src/did/make_did.c) target_include_directories(did.exe PRIVATE src/did ${MOTIF_INCLUDE_DIR}) target_compile_options(did.exe PRIVATE -Wno-incompatible-pointer-types) -target_link_libraries(did.exe PRIVATE Online::dim X11::X11 X11::Xt ${MOTIF_LIBRARIES}) +target_link_libraries(did.exe PRIVATE Online::dim ${MOTIF_LIBRARIES} X11::X11 X11::Xt) dim_exe(webdid src/webDid/webDid.c diff --git a/build_standalone.sh b/build_standalone.sh index bef8448f3..dd88a1bfc 100755 --- a/build_standalone.sh +++ b/build_standalone.sh @@ -157,11 +157,15 @@ elif [ ! -d ${lcg_view} ]; then # exit 1; fi; +build_prefix=dataflow; +if test "${eb_only}" = "ON"; then + build_prefix=ebonly; +fi; if test -z "${build_dir}"; then - build_dir=${source_dir}/dataflow_build.${binary_tag}; + build_dir=${source_dir}/build.${build_prefix}.${binary_tag}; fi; if test -z "${install_dir}"; then - install_dir=${source_dir}/dataflow_install.${binary_tag}; + install_dir=${source_dir}/install.${build_prefix}.${binary_tag}; fi; # lcg_view=`realpath ${lcg_view}`; diff --git a/cmake/OnlineStandalone.cmake b/cmake/OnlineStandalone.cmake index 885b8a7d7..1d32977a3 100644 --- a/cmake/OnlineStandalone.cmake +++ b/cmake/OnlineStandalone.cmake @@ -46,7 +46,6 @@ macro(online_locate_package var alias) #message(status "++++ ONLINE_BINARY_TAG: ${ONLINE_BINARY_TAG}") #message(status "++++ ONLINE_LCG_VIEW_LOCATION: ${ONLINE_LCG_VIEW_LOCATION}") endif() - execute_process( COMMAND python ${ONLINE_FIND_PACKAGE_PATH} --package=${alias} --build=${ONLINE_BINARY_TAG} @@ -223,14 +222,45 @@ endmacro(online_set_compiler_flags) # # # ======================================================================= +macro(online_import_pluginmanager source_dir) + find_library(PLUGINMGR GaudiPluginService) # PATH ${source_dir}/lib/libGaudiPluginService1.so) + if ( ${PLUGINMGR} STREQUAL "PLUGINMGR-NOTFOUND" ) + message(ERROR "+++ Plugin manager not found: ${PLUGINMGR}") + return() + endif() + add_library(GaudiPluginService IMPORTED SHARED GLOBAL) + set_property(TARGET GaudiPluginService PROPERTY IMPORTED_LOCATION ${PLUGINMGR}) + target_include_directories(GaudiPluginService INTERFACE + $<BUILD_INTERFACE:${source_dir}/include/> + $<INSTALL_INTERFACE:include/>) + add_library(Gaudi::GaudiPluginService ALIAS GaudiPluginService) + message(STATUS "|+++> Importing Gaudi::GaudiPluginService ${PLUGINMGR}" ) + # + find_program(LISTCOMPONENTS listcomponents) # PATHS ${source_dir}/bin/listcomponents) + if ( ${LISTCOMPONENTS} STREQUAL "LISTCOMPONENTS-NOTFOUND" ) + message(ERROR "+++ listcomponents not found: ${LISTCOMPONENTS}") + return() + endif() + add_executable(listcomponents IMPORTED) + set_property(TARGET listcomponents PROPERTY IMPORTED_LOCATION ${LISTCOMPONENTS}) + add_executable(Gaudi::listcomponents ALIAS listcomponents) + message(STATUS "|+++> Importing Gaudi::listcomponents ${LISTCOMPONENTS}" ) +endmacro(online_import_pluginmanager) +# +# +# ======================================================================= function(online_build_pluginmanager source_dir) add_library(GaudiPluginService SHARED ${source_dir}/src/PluginServiceV1.cpp ${source_dir}/src/PluginServiceV2.cpp) target_include_directories(GaudiPluginService PRIVATE ${source_dir}/include) - target_include_directories(GaudiPluginService INTERFACE ${source_dir}/include) + target_include_directories(GaudiPluginService INTERFACE + $<BUILD_INTERFACE:${source_dir}/include/> + $<INSTALL_INTERFACE:include/>) target_compile_options(GaudiPluginService PRIVATE -Wno-unused-function -Wno-shadow) target_link_libraries(GaudiPluginService stdc++fs Threads::Threads ${CMAKE_DL_LIBS}) add_library(Gaudi::GaudiPluginService ALIAS GaudiPluginService) - install(TARGETS GaudiPluginService EXPORT Online LIBRARY DESTINATION "${ONLINE_INSTALL_LIBDIR}") + install(TARGETS GaudiPluginService EXPORT Online + LIBRARY DESTINATION "${ONLINE_INSTALL_LIBDIR}" + INCLUDES DESTINATION "${ONLINE_INSTALL_INCLUDEDIR}") # add_executable(listcomponents ${source_dir}/src/listcomponents.cpp ${source_dir}/src/PluginServiceV1.cpp @@ -240,7 +270,6 @@ function(online_build_pluginmanager source_dir) target_link_libraries(listcomponents stdc++fs Threads::Threads ${CMAKE_DL_LIBS}) add_executable(Gaudi::listcomponents ALIAS listcomponents) install(TARGETS listcomponents RUNTIME DESTINATION ${ONLINE_INSTALL_BINDIR}) - install(DIRECTORY ${source_dir}/include/ DESTINATION "${ONLINE_INSTALL_INCLUDEDIR}") endfunction(online_build_pluginmanager) # # diff --git a/cmake/find_package_path.py b/cmake/find_package_path.py index 4ba623160..8f84c794a 100644 --- a/cmake/find_package_path.py +++ b/cmake/find_package_path.py @@ -17,6 +17,18 @@ def find_directory(top, name): return (name, package, fpackage, ) return None +def find_directory2(top, name): + req_package = (name+'-').upper() + package_names = os.listdir(top) + for package in package_names: + fpackage = top + '/' + package + if package == '.cvmfscatalog' or not os.path.exists(fpackage) or not os.path.isdir(fpackage): + continue + if package.upper().find(req_package) < 0: + continue + return (name, package, fpackage, ) + return None + def get_package_version(fpackage): package_versions = os.listdir(fpackage) for version in package_versions: @@ -66,5 +78,13 @@ if __name__ == '__main__': if build: print(str(os.path.realpath(build[2]))) sys.exit(0) + package = find_directory2(opts.view+'/lib/cmake', opts.package) + if package: + print(str(os.path.realpath(package[2]))) + sys.exit(0) + package = find_directory2(opts.view+'/lib64/cmake', opts.package) + if package: + print(str(os.path.realpath(package[2]))) + sys.exit(0) print('UNRESOLVED') diff --git a/cmake/thisonline.sh.in b/cmake/thisonline.sh.in index 8e1e532dd..b3ada089a 100644 --- a/cmake/thisonline.sh.in +++ b/cmake/thisonline.sh.in @@ -80,11 +80,14 @@ fi; # #----------------------------------------------------------------------------- export ROOTSYS=@ONLINE_ROOT_SYS@; -if test ! -f ${ROOTSYS}/bin/thisroot.sh; then - echo "No ROOT setup found. This installation setup will not work!"; +if [ -n "@ONLINE_LCG_VIEW_SETUP@" ]; then + source @ONLINE_LCG_VIEW_SETUP@/setup.sh; +else + if test ! -f ${ROOTSYS}/bin/thisroot.sh; then + echo "No ROOT setup found. This installation setup will not work!"; + fi; + . ${ROOTSYS}/bin/thisroot.sh; fi; -# -. ${ROOTSYS}/bin/thisroot.sh; #----PATH--------------------------------------------------------------------- online_add_path PATH ${THIS}/@ONLINE_INSTALL_BINDIR@; #----LIBRARY_PATH------------------------------------------------------------- -- GitLab From d7e6f3b83bb040178013fe2a9d30d5aab89a74c1 Mon Sep 17 00:00:00 2001 From: Markus Frank <Markus.Frank@cern.ch> Date: Tue, 20 Sep 2022 09:10:41 +0200 Subject: [PATCH 5/5] Update ROMon monitoring information --- MyOnline/ROMon.xml/EBSCIFI.xml | 1 + MyOnline/ROMon.xml/TaskInventory.xml | 8 ++------ 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/MyOnline/ROMon.xml/EBSCIFI.xml b/MyOnline/ROMon.xml/EBSCIFI.xml index 0c39cb432..7852ca65e 100644 --- a/MyOnline/ROMon.xml/EBSCIFI.xml +++ b/MyOnline/ROMon.xml/EBSCIFI.xml @@ -51,5 +51,6 @@ <Node name="SCEB23" type="EventBuilder"/> <Node name="SCEB24" type="EventBuilder"/> + <Node name="SUEB02" type="EventBuilder"/> </NodeList> </TaskInventory> diff --git a/MyOnline/ROMon.xml/TaskInventory.xml b/MyOnline/ROMon.xml/TaskInventory.xml index e21c840b6..5541662e1 100644 --- a/MyOnline/ROMon.xml/TaskInventory.xml +++ b/MyOnline/ROMon.xml/TaskInventory.xml @@ -165,10 +165,6 @@ <!-- =================================================== --> <!-- =============== Event builder nodes =============== --> -<ConnectionList name="StandardEB"> - <Connection name="ecs03"/> -</ConnectionList> - <ConnectionList name="EventBuilder"> <Connection name="DATAFLOW01"/> <Connection name="DATAFLOW02"/> @@ -183,7 +179,7 @@ <Task name="TANServ"/> <Task name="ROcollect"/> <Task name="pingSrv"/> - <ConnectionList name="StandardEB"/> + <ConnectionList name="Standard"/> <ConnectionList name="EventBuilder"/> </NodeType> @@ -210,7 +206,7 @@ <Task name="ROpublish_VELO"/> <Task name="ROpublish_DATAFLOW"/> - <ConnectionList name="StandardEB"/> + <ConnectionList name="Standard"/> <ConnectionList name="EventBuilder"/> </NodeType> <!-- =================================================== --> -- GitLab