diff --git a/Projects/AnalysisBase/build.sh b/Projects/AnalysisBase/build.sh index efcbd1a90f2e6e28b7a4f6d17eb2a0fe15455275..f84b66c19b136c9341d55fb1b8574d95e2439cbf 100755 --- a/Projects/AnalysisBase/build.sh +++ b/Projects/AnalysisBase/build.sh @@ -4,6 +4,8 @@ # script in this directory. # +_time_="/usr/bin/time -f time::\t%C::\treal:\t%E\tuser:\t%U\tsys:\t%S\n " + # Function printing the usage information for the script usage() { echo "Usage: build.sh [-t type] [-b dir] [-g generator] [-c] [-m] [-i] [-p] [-a]" @@ -118,7 +120,7 @@ if [ -n "$EXE_CMAKE" ]; then fi # Now run the actual CMake configuration: - time cmake -G "${GENERATOR}" \ + $_time_ cmake -G "${GENERATOR}" \ -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ ${USE_LAUNCHERS} \ ${AnalysisBaseSrcDir} 2>&1 | tee cmake_config.log @@ -136,26 +138,26 @@ if [ -n "$EXE_MAKE" ]; then # In order to build the project in a nightly setup, allowing for some # build steps to fail while still continuing, we need to use "make" # directly. Only allowing the usage of the Makefile generator. - time make -k 2>&1 | tee cmake_build.log + $_time_ make -k 2>&1 | tee cmake_build.log else # However in a non-nightly setup we can just rely on CMake to start # the build for us. In this case we can use any generator we'd like # for the build. Notice however that the installation step can still # be only done correctly by using GNU Make directly. - time cmake --build . 2>&1 | tee cmake_build.log + $_time_ cmake --build . 2>&1 | tee cmake_build.log fi fi # Install the results: if [ -n "$EXE_INSTALL" ]; then - time make install/fast \ + $_time_ make install/fast \ DESTDIR=${BUILDDIR}/install/AnalysisBase/${NICOS_PROJECT_VERSION} \ 2>&1 | tee cmake_install.log fi # Build an RPM for the release: if [ -n "$EXE_CPACK" ]; then - time cpack 2>&1 | tee cmake_cpack.log + $_time_ cpack 2>&1 | tee cmake_cpack.log FILES=$(ls AnalysisBase*.rpm AnalysisBase*.dmg AnalysisBase*.tar.gz) cp ${FILES} ${BUILDDIR}/ fi diff --git a/Projects/AnalysisTop/build.sh b/Projects/AnalysisTop/build.sh index 30b07b4a7a2e73ec0a3dc24c5015e3f6bb1091e4..f4d82b2e8bf92b560733ccd6fb7915b0f6508226 100755 --- a/Projects/AnalysisTop/build.sh +++ b/Projects/AnalysisTop/build.sh @@ -4,6 +4,8 @@ # script in this directory. # +_time_="/usr/bin/time -f time::\t%C::\treal:\t%E\tuser:\t%U\tsys:\t%S\n " + # Function printing the usage information for the script usage() { echo "Usage: build.sh [-t type] [-b dir] [-g generator] [-c] [-m] [-i] [-p] [-a]" @@ -116,7 +118,7 @@ if [ -n "$EXE_CMAKE" ]; then fi # Now run the actual CMake configuration: - time cmake -G "${GENERATOR}" \ + $_time_ cmake -G "${GENERATOR}" \ -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ ${USE_LAUNCHERS} \ ${AnalysisTopSrcDir} 2>&1 | tee cmake_config.log @@ -134,26 +136,26 @@ if [ -n "$EXE_MAKE" ]; then # In order to build the project in a nightly setup, allowing for some # build steps to fail while still continuing, we need to use "make" # directly. Only allowing the usage of the Makefile generator. - time make -k 2>&1 | tee cmake_build.log + $_time_ make -k 2>&1 | tee cmake_build.log else # However in a non-nightly setup we can just rely on CMake to start # the build for us. In this case we can use any generator we'd like # for the build. Notice however that the installation step can still # be only done correctly by using GNU Make directly. - time cmake --build . 2>&1 | tee cmake_build.log + $_time_ cmake --build . 2>&1 | tee cmake_build.log fi fi # Install the results: if [ -n "$EXE_INSTALL" ]; then - time make install/fast \ + $_time_ make install/fast \ DESTDIR=${BUILDDIR}/install/AnalysisTop/${NICOS_PROJECT_VERSION} \ 2>&1 | tee cmake_install.log fi # Build an RPM for the release: if [ -n "$EXE_CPACK" ]; then - time cpack 2>&1 | tee cmake_cpack.log + $_time_ cpack 2>&1 | tee cmake_cpack.log FILES=$(ls AnalysisTop*.rpm AnalysisTop*.dmg AnalysisTop*.tar.gz) cp ${FILES} ${BUILDDIR}/ fi diff --git a/Projects/AthDataQuality/build.sh b/Projects/AthDataQuality/build.sh index b237408e895926c93384dbe2560cef2f1354cf5b..59138dcad468c1eb1d0cdf26c518b60fc3562391 100755 --- a/Projects/AthDataQuality/build.sh +++ b/Projects/AthDataQuality/build.sh @@ -4,6 +4,8 @@ # scripts in this directory. # +_time_="/usr/bin/time -f time::\t%C::\treal:\t%E\tuser:\t%U\tsys:\t%S\n " + # Function printing the usage information for the script usage() { echo "Usage: build.sh [-t build type] [-b build dir] [-c] [-m] [-i] [-p] [-a] [-x] [-N]" @@ -110,7 +112,7 @@ if [ -n "$EXE_CMAKE" ]; then # from scratch in an incremental build. rm -f CMakeCache.txt # Now run the actual CMake configuration: - { time cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ + { $_time_ cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ ${EXTRACMAKE} \ -DCTEST_USE_LAUNCHERS:BOOL=TRUE \ ${AthDataQualitySrcDir}; } 2>&1 | tee cmake_config.log @@ -130,17 +132,17 @@ if [ -n "$EXE_MAKE" ]; then # the build_env.sh script. rm -f ${platform}/share/clid.db # Build the project. - { time ${BUILDTOOL}; } 2>&1 | tee cmake_build.log + { $_time_ ${BUILDTOOL}; } 2>&1 | tee cmake_build.log fi # Install the results: if [ -n "$EXE_INSTALL" ]; then - { time DESTDIR=${BUILDDIR}/install/AthDataQuality/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ + { $_time_ DESTDIR=${BUILDDIR}/install/AthDataQuality/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ 2>&1 | tee cmake_install.log fi # Build an RPM for the release: if [ -n "$EXE_CPACK" ]; then - time cpack 2>&1 | tee cmake_cpack.log + $_time_ cpack 2>&1 | tee cmake_cpack.log cp AthDataQuality*.rpm ${BUILDDIR}/ fi diff --git a/Projects/AthSimulation/build.sh b/Projects/AthSimulation/build.sh index 651433bbb7c0ff0a7fbea1a36521d84579c0b33f..06e572f31d1fdf4721552cdc4d8640e1fee8cf97 100755 --- a/Projects/AthSimulation/build.sh +++ b/Projects/AthSimulation/build.sh @@ -4,6 +4,8 @@ # scripts in this directory. # +_time_="/usr/bin/time -f time::\t%C::\treal:\t%E\tuser:\t%U\tsys:\t%S\n " + # Function printing the usage information for the script usage() { echo "Usage: build.sh [-t build type] [-b build dir] [-c] [-m] [-i] [-p] [-a] [-x] [-N]" @@ -112,7 +114,7 @@ if [ -n "$EXE_CMAKE" ]; then # from scratch in an incremental build. rm -f CMakeCache.txt # Now run the actual CMake configuration: - { time cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ + { $_time_ cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ ${EXTRACMAKE} \ -DCTEST_USE_LAUNCHERS:BOOL=TRUE \ ${AthSimulationSrcDir}; } 2>&1 | tee cmake_config.log @@ -132,17 +134,17 @@ if [ -n "$EXE_MAKE" ]; then # the build_env.sh script. rm -f ${platform}/share/clid.db # Build the project. - { time ${BUILDTOOL}; } 2>&1 | tee cmake_build.log + { $_time_ ${BUILDTOOL}; } 2>&1 | tee cmake_build.log fi # Install the results: if [ -n "$EXE_INSTALL" ]; then - { time DESTDIR=${BUILDDIR}/install/AthSimulation/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ + { $_time_ DESTDIR=${BUILDDIR}/install/AthSimulation/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ 2>&1 | tee cmake_install.log fi # Build an RPM for the release: if [ -n "$EXE_CPACK" ]; then - { time cpack; } 2>&1 | tee cmake_cpack.log + { $_time_ cpack; } 2>&1 | tee cmake_cpack.log cp AthSimulation*.rpm ${BUILDDIR}/ fi diff --git a/Projects/Athena/build.sh b/Projects/Athena/build.sh index 761858914d0e9fd095be09e5c817655dee652b10..a81d8fab8d594a97a444013a0725ef8e7339ac9a 100755 --- a/Projects/Athena/build.sh +++ b/Projects/Athena/build.sh @@ -4,6 +4,8 @@ # scripts in this directory. # +_time_="/usr/bin/time -f time::\t%C::\treal:\t%E\tuser:\t%U\tsys:\t%S\n " + # Function printing the usage information for the script usage() { echo "Usage: build.sh [-t build type] [-b build dir] [-c] [-m] [-i] [-p] [-a] [-x] [-N]" @@ -127,7 +129,7 @@ if [ -n "$EXE_CMAKE" ]; then # from scratch in an incremental build. rm -f CMakeCache.txt # Now run the actual CMake configuration: - { time cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ + { ${_time_} cmake ${BUILDTOOLTYPE} -DCMAKE_BUILD_TYPE:STRING=${BUILDTYPE} \ ${EXTRACMAKE} \ -DCTEST_USE_LAUNCHERS:BOOL=TRUE \ ${AthenaSrcDir}; } 2>&1 | tee cmake_config.log @@ -162,7 +164,7 @@ if [ -n "$EXE_MAKE" ]; then # the build_env.sh script. rm -f ${platform}/share/clid.db # Build the project. - { time ${BUILDTOOL}; } 2>&1 | tee cmake_build.log + { ${_time_} ${BUILDTOOL}; } 2>&1 | tee cmake_build.log fi { @@ -175,16 +177,16 @@ fi # Install the results: if [ -n "$EXE_INSTALL" ]; then - { time DESTDIR=${BUILDDIR}/install/Athena/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ + { ${_time_} DESTDIR=${BUILDDIR}/install/Athena/${NICOS_PROJECT_VERSION} ${BUILDTOOL} ${INSTALLRULE}; } \ 2>&1 | tee cmake_install.log fi #^^^ do we need to analyze local install logs? # Build an RPM for the release: if [ -n "$EXE_CPACK" ]; then - { time cpack; } 2>&1 | tee cmake_cpack.log + { ${_time_} cpack; } 2>&1 | tee cmake_cpack.log if [ "$BUILDTYPE" = "RelWithDebInfo" ]; then - { time cpack --config CPackDbgRPMConfig.cmake; } 2>&1 | tee -a cmake_cpack.log + { ${_time_} cpack --config CPackDbgRPMConfig.cmake; } 2>&1 | tee -a cmake_cpack.log fi cp Athena*.rpm ${BUILDDIR}/ fi