From 51f26f94838a6502e9baa26b028dcc2793f0e770 Mon Sep 17 00:00:00 2001 From: tamasmeszaros Date: Fri, 4 Oct 2019 14:27:51 +0200 Subject: [PATCH] Fix for data dir path on windows --- tests/CMakeLists.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 8ed5d6559..0a22c5f23 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -11,7 +11,7 @@ add_library(Catch2::Catch2 ALIAS Catch2) include(Catch) add_library(test_catch2_common INTERFACE) -target_compile_definitions(test_catch2_common INTERFACE TEST_DATA_DIR="${TEST_DATA_DIR}") +target_compile_definitions(test_catch2_common INTERFACE TEST_DATA_DIR=R"\(${TEST_DATA_DIR}\)") target_link_libraries(test_catch2_common INTERFACE Catch2::Catch2) add_library(test_common INTERFACE) @@ -24,7 +24,7 @@ target_link_libraries(test_common INTERFACE test_catch2_common) # DEPRECATED: find_package(GTest REQUIRED) add_library(test_gtest_common INTERFACE) -target_compile_definitions(test_gtest_common INTERFACE TEST_DATA_DIR="${TEST_DATA_DIR}") +target_compile_definitions(test_gtest_common INTERFACE TEST_DATA_DIR=R"\(${TEST_DATA_DIR}\)") target_link_libraries(test_gtest_common INTERFACE GTest::GTest GTest::Main) add_subdirectory(libnest2d)