Skip to content

Export Sanitizer Update, master branch (2022.03.23.)

Updated how the project configurations would be exported and sanitized, providing a different solution for auto-detecting the kind of problems that were reported in ATLINFR-4465. @fwinkl, as we discussed in athena!51474 (closed), this is how I can imagine this working.

I did all the following:

  • Introduced the <PROJECT_NAME>_INSTALL_DIR and <PROJECT_NAME>_PLATFORM variables for the installed projects, and made use of them right away during the sanitastion process of the exported CMake configurations.
    • I made the printouts from the ATLAS projects when "they are found" a little more standard at the same time. Now they will show up like the following in WorkDir builds:
...
-- Found Athena: /data/hdd-4tb/projects/ATLINFR-4465/install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig.cmake (found version "22.0.61") 
...
-- Found AthenaExternals: /data/hdd-4tb/projects/ATLINFR-4465/install/AthenaExternals/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaExternalsConfig.cmake (found suitable exact version "22.0.61") 
...
  • Added checks for direct references to /cvmfs, /eos and /afs paths for the exported configurations. As these should never be there.
  • Removed the sanitization of TDAQ paths from all the projects that are not expected to depend on TDAQ. So that in case a TDAQ dependency sneaks in, we would see a warning during the release installation about direct /cvmfs references.

Note that I tried to clean up the sanitizer scripts a bit. And had to realise while doing that, that it would be possible to not have separate scripts for every project after all. But that would've required even more changes, and I didn't want to change too many things at once. But I do plan to reduce the repetitions in this code in a future MR.

I did quite some testing on this... I built full versions of AnalysisBase and Athena locally, to test that I could successfully build WorkDir projects on top of them. I think this type of code should work. (Famous last words...)

When I re-introduce one of the previous errors with

diff --git a/Generators/TruthUtils/CMakeLists.txt b/Generators/TruthUtils/CMakeLists.txt
index 51e9a11510c..e534a4a24c9 100644
--- a/Generators/TruthUtils/CMakeLists.txt
+++ b/Generators/TruthUtils/CMakeLists.txt
@@ -18,7 +18,7 @@ endif()
 atlas_add_library( TruthUtils
    TruthUtils/*.h Root/*.cxx
    PUBLIC_HEADERS TruthUtils
-   INCLUDE_DIRS ${HEPUTILS_INCLUDE_DIRS} ${MCUTILS_INCLUDE_DIRS}
+   INCLUDE_DIRS ${HEPUTILS_INCLUDE_DIRS} ${MCUTILS_INCLUDE_DIR}
    LINK_LIBRARIES ${HEPUTILS_LIBRARIES} ${MCUTILS_LIBRARIES} ${extra_libs}
    PRIVATE_LINK_LIBRARIES CxxUtils )

, the Athena installation prints this warning:

...
-- Up-to-date: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/LCGConfig.cmake
-- Up-to-date: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/LCGConfig-version.cmake
-- Installing: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/./compilers.txt
-- Old export file "../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-targets.cmake" will be replaced.  Removing files [/data/hdd-4tb/projects/ATLINFR-4465/athena-build/../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-targets-release.cmake].
-- Installing: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-targets.cmake
-- Installing: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-targets-release.cmake
CMake Warning at CMakeFiles/atlas_export_sanitizer.cmake:75 (message):
  Direct reference to "/cvmfs" found in
  "../install//Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-targets.cmake"
Call Stack (most recent call first):
  cmake_install.cmake:127 (include)


-- Up-to-date: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig.cmake
-- Up-to-date: ../install/Athena/22.0.61/InstallArea/x86_64-centos7-gcc11-opt/cmake/AthenaConfig-version.cmake
...

@aundrus, I only realised while working on this, that these warnings will actually show up during the installation of the main projects. But the installation logs are not shown anywhere on the NICOS pages. 😦

https://bigpanda.cern.ch/nview/?nightly=master_Athena_x86_64-centos7-gcc11-opt

So this warning at the moment will be completely invisible to the shifters. Would it be possible to present the cmake_install.log files on the web interface, and scan them for CMake warnings/errors? (I guess I should open a JIRA ticket about that, right...?)

Merge request reports