1
0
mirror of synced 2024-05-29 08:48:16 +02:00
modern-cmake/examples/root-simple/CMakeLists.txt
2019-08-08 16:18:42 -04:00

508 B

[main]

cmake_minimum_required(VERSION 3.1...3.15)

project(RootSimpleExample LANGUAGES CXX)

Finding the ROOT package

[find_package]

find_package(ROOT 6.16 CONFIG REQUIRED)

[find_package]

Adding an executable program and linking to needed ROOT libraries

add_executable(RootSimpleExample SimpleExample.cxx) target_link_libraries(RootSimpleExample PUBLIC ROOT::Physics)

[main]

enable_testing() add_test(NAME RootSimpleExample COMMAND RootSimpleExample)