Skip to content
Snippets Groups Projects
Commit 8dd796ad authored by Attila Krasznahorkay's avatar Attila Krasznahorkay Committed by Tadej Novak
Browse files

AthSimulation CMake Fixes, main branch (2024.02.28.)

Make it possible to use AthSimulation(Externals) from CVMFS.

One has to tell AtlasLCG to not look for any "generator packages", and
one also has to make sure to set up LCG early enough during the
CMake configuration. So that building code against AthSimulation would
work as it should.
parent 5b946d6e
No related branches found
No related tags found
No related merge requests found
# Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
# Set up the project.
cmake_minimum_required( VERSION 3.6 )
......@@ -22,6 +22,7 @@ set( ATLAS_PYTHON_CHECKER ${ATLAS_FLAKE8}
find_package( AtlasCMake QUIET )
# Find the base project(s):
set( LCG_COMPONENTS "externals" CACHE STRING "LCG components to set up" )
find_package( AthSimulationExternals REQUIRED )
find_package( Gaudi )
......
# Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
# Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
#
# Pre-config script to propagate variables to downstream projects
#
......@@ -29,6 +29,13 @@ if( @CMAKE_PROJECT_NAME@_FIND_QUIETLY )
set( _quietFlag QUIET )
endif()
# Set up the correct version of LCG. While AthSimulationExternals does this as
# well, we need to do it explicitly here, to make the following find_package
# calls find the packages correctly.
set( LCG_VERSION_POSTFIX @LCG_VERSION_POSTFIX@ )
set( LCG_COMPONENTS "@LCG_COMPONENTS@" CACHE STRING "LCG components to set up" )
find_package( LCG @LCG_VERSION_NUMBER@ REQUIRED EXACT ${_quietFlag} )
# Imported target(s) used by the project.
find_package( nlohmann_json ${_quietFlag} )
find_package( GTest ${_quietFlag} )
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment