Back to home page

EIC code displayed by LXR

 
 

    


Warning, /acts/Detray/extern/covfie/CMakeLists.txt is written in an unsupported language. File is not indexed.

0001 # This file is part of the ACTS project.
0002 #
0003 # Copyright (C) 2016 CERN for the benefit of the ACTS project
0004 #
0005 # This Source Code Form is subject to the terms of the Mozilla Public
0006 # License, v. 2.0. If a copy of the MPL was not distributed with this
0007 # file, You can obtain one at https://mozilla.org/MPL/2.0/.
0008 
0009 # CMake include(s).
0010 cmake_minimum_required(VERSION 3.14)
0011 include(FetchContent)
0012 
0013 # Silence FetchContent warnings with CMake >=3.24.
0014 if(POLICY CMP0135)
0015     cmake_policy(SET CMP0135 NEW)
0016 endif()
0017 
0018 # Tell the user what's happening.
0019 message(STATUS "Fetching covfie as part of the Detray project")
0020 
0021 # Declare where to get covfie from.
0022 set(DETRAY_COVFIE_SOURCE
0023     "URL;https://github.com/acts-project/covfie/archive/refs/tags/v${DETRAY_COVFIE_VERSION}.tar.gz;URL_MD5;${DETRAY_COVFIE_DIGEST}"
0024     CACHE STRING
0025     "Source for covfie, when built as part of this project"
0026 )
0027 mark_as_advanced(DETRAY_COVFIE_SOURCE)
0028 
0029 # Mark the import as a system library on modern CMake versions
0030 if(CMAKE_VERSION VERSION_GREATER_EQUAL 3.25.0)
0031     set(DETRAY_COVFIE_SOURCE_FULL "${DETRAY_COVFIE_SOURCE};SYSTEM")
0032 else()
0033     set(DETRAY_COVFIE_SOURCE_FULL "${DETRAY_COVFIE_SOURCE}")
0034 endif()
0035 mark_as_advanced(DETRAY_COVFIE_SOURCE_FULL)
0036 
0037 FetchContent_Declare(covfie ${DETRAY_COVFIE_SOURCE_FULL})
0038 
0039 # Options used for covfie.
0040 set(COVFIE_BUILD_EXAMPLES OFF CACHE BOOL "Build covfie examples")
0041 set(COVFIE_BUILD_TESTS OFF CACHE BOOL "Build covfie tests")
0042 set(COVFIE_BUILD_BENCHMARKS OFF CACHE BOOL "Build covfie benchmarks")
0043 
0044 set(COVFIE_PLATFORM_CPU ON CACHE BOOL "Enable covfie CPU platform")
0045 
0046 set(COVFIE_PLATFORM_HIP
0047     ${DETRAY_BUILD_HIP}
0048     CACHE BOOL
0049     "Enable covfie HIP platform"
0050 )
0051 set(COVFIE_PLATFORM_CUDA
0052     ${DETRAY_BUILD_CUDA}
0053     CACHE BOOL
0054     "Enable covfie CUDA platform"
0055 )
0056 
0057 set(COVFIE_REQUIRE_CXX20 OFF CACHE BOOL "Enable covfie C++20 requirement")
0058 set(COVFIE_QUIET ON CACHE BOOL "Quiet covfie feature warnings")
0059 
0060 # Get it into the current directory.
0061 FetchContent_MakeAvailable(covfie)