[CMake] restore compability with 3.15

This commit is contained in:
Mathis Logemann 2021-10-13 09:04:26 +02:00
parent 6dee79f442
commit 83b4989bd4
2 changed files with 2 additions and 4 deletions

View file

@ -1,9 +1,7 @@
if(BUILD_DEMO_VIEWER) if(BUILD_DEMO_VIEWER)
message(STATUS "Building demo viewer")
add_subdirectory(viewer) add_subdirectory(viewer)
endif() endif()
if(BUILD_DEMO_CPP) if(BUILD_DEMO_CPP)
message(STATUS "Building c++ demo app")
add_subdirectory(c++) add_subdirectory(c++)
endif() endif()

View file

@ -109,8 +109,8 @@ target_link_libraries(mapnik-test-unit PUBLIC
PostgreSQL::PostgreSQL PostgreSQL::PostgreSQL
) )
# workaround since the "offical" include dir would be <catch2/catch.hpp> # workaround since the "offical" include dir would be <catch2/catch.hpp>
file(COPY_FILE catch_ext.hpp "${CMAKE_CURRENT_BINARY_DIR}/catch_ext.hpp") file(COPY catch_ext.hpp DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
file(COPY_FILE cleanup.hpp "${CMAKE_CURRENT_BINARY_DIR}/cleanup.hpp") file(COPY cleanup.hpp DESTINATION "${CMAKE_CURRENT_BINARY_DIR}")
target_include_directories(mapnik-test-unit PRIVATE "${catch2_SOURCE_DIR}/single_include/catch2" ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR}) target_include_directories(mapnik-test-unit PRIVATE "${catch2_SOURCE_DIR}/single_include/catch2" ${CMAKE_CURRENT_BINARY_DIR} ${CMAKE_CURRENT_SOURCE_DIR})
add_executable(agg_rasterizer_integer_overflow_test standalone/agg_rasterizer_integer_overflow_test.cpp) add_executable(agg_rasterizer_integer_overflow_test standalone/agg_rasterizer_integer_overflow_test.cpp)