2019-04-09 15:29:07 +02:00
|
|
|
cmake_minimum_required(VERSION 3.5 FATAL_ERROR)
|
|
|
|
|
|
|
|
|
|
project(CPMTest)
|
|
|
|
|
|
2019-04-09 16:15:36 +02:00
|
|
|
include(${CMAKE_CURRENT_SOURCE_DIR}/../../cmake/CPM.cmake)
|
2019-04-09 15:29:07 +02:00
|
|
|
|
2019-04-14 14:49:35 +02:00
|
|
|
# ignore locally installed projects for reproducable builds
|
|
|
|
|
set(CPM_REMOTE_PACKAGES_ONLY ON CACHE INTERNAL "")
|
|
|
|
|
|
|
|
|
|
# util library
|
2019-04-09 15:29:07 +02:00
|
|
|
CPMAddPackage(
|
|
|
|
|
NAME LHC
|
|
|
|
|
GIT_REPOSITORY https://github.com/TheLartians/LHC.git
|
2019-04-14 14:49:35 +02:00
|
|
|
VERSION 0.7
|
2019-04-09 15:29:07 +02:00
|
|
|
)
|
|
|
|
|
|
2019-04-17 13:01:56 +02:00
|
|
|
# will be ignored as newer version already added
|
2019-04-11 10:13:28 +02:00
|
|
|
CPMAddPackage(
|
|
|
|
|
NAME LHC
|
|
|
|
|
GIT_REPOSITORY https://github.com/TheLartians/LHC.git
|
2019-04-17 13:01:56 +02:00
|
|
|
VERSION 0.2
|
2019-04-11 10:13:28 +02:00
|
|
|
)
|
|
|
|
|
|
2019-04-14 14:49:35 +02:00
|
|
|
# language bindings
|
2019-04-14 15:33:57 +02:00
|
|
|
# uses git tag instead of version identifier
|
2019-04-17 13:01:56 +02:00
|
|
|
# depends on visitor library that depends on Event library and LHC
|
|
|
|
|
# CMake configuration arguments passed via OPTIONS
|
2019-04-09 15:29:07 +02:00
|
|
|
CPMAddPackage(
|
2019-04-14 14:49:35 +02:00
|
|
|
NAME Glue
|
|
|
|
|
GIT_TAG 78af65625751ad15a42ca52b842863e85b5d2adc
|
|
|
|
|
GIT_REPOSITORY https://github.com/TheLartians/Glue.git
|
2019-04-17 13:01:56 +02:00
|
|
|
VERSION 0.5.1
|
2019-04-14 14:49:35 +02:00
|
|
|
OPTIONS
|
|
|
|
|
"GLUE_ENABLE_LUA ON"
|
|
|
|
|
"GLUE_BUILD_LUA ON"
|
2019-04-09 15:29:07 +02:00
|
|
|
)
|
|
|
|
|
|
2019-04-14 14:49:35 +02:00
|
|
|
# parser library
|
2019-04-17 13:01:56 +02:00
|
|
|
# depends on LHC and Glue
|
2019-04-09 15:29:07 +02:00
|
|
|
CPMAddPackage(
|
|
|
|
|
NAME LarsParser
|
|
|
|
|
GIT_REPOSITORY https://github.com/TheLartians/Parser.git
|
2019-04-14 15:33:57 +02:00
|
|
|
VERSION 1.8
|
2019-04-14 14:49:35 +02:00
|
|
|
OPTIONS
|
2019-04-14 15:33:57 +02:00
|
|
|
"LARS_PARSER_BUILD_GLUE_EXTENSION ON"
|
2019-04-09 15:29:07 +02:00
|
|
|
)
|
|
|
|
|
|
2019-04-09 15:51:25 +02:00
|
|
|
# add executable
|
2019-04-16 19:57:05 +02:00
|
|
|
add_executable(cpm-test-complex main.cpp)
|
2019-04-18 12:47:22 +02:00
|
|
|
set_target_properties(cpm-test-complex PROPERTIES CXX_STANDARD 17)
|
2019-04-16 19:57:05 +02:00
|
|
|
target_link_libraries(cpm-test-complex LHC LarsParser Glue)
|
2019-04-09 15:51:25 +02:00
|
|
|
|
|
|
|
|
# tests
|
|
|
|
|
enable_testing()
|
2019-04-16 19:57:05 +02:00
|
|
|
add_test(cpm-test-complex cpm-test-complex)
|