summaryrefslogtreecommitdiff
path: root/infrastructure
diff options
context:
space:
mode:
authorChris Wilson <chris+github@qwirx.com>2016-09-02 23:45:13 +0100
committerChris Wilson <chris+github@qwirx.com>2016-08-28 22:09:52 +0100
commit8c092e87b40cccc046aa4b0a215a4798548224b0 (patch)
tree41c2a6116a74fe137d3248592012c54a9f95e2db /infrastructure
parent756222dd41fdee629e5dc928f2ddbe3ed524f6ed (diff)
Use builtin TO_NATIVE_PATH in CMake instead of rolling our own.
Diffstat (limited to 'infrastructure')
-rw-r--r--infrastructure/cmake/CMakeLists.txt10
1 files changed, 1 insertions, 9 deletions
diff --git a/infrastructure/cmake/CMakeLists.txt b/infrastructure/cmake/CMakeLists.txt
index a63f838a..21d35e43 100644
--- a/infrastructure/cmake/CMakeLists.txt
+++ b/infrastructure/cmake/CMakeLists.txt
@@ -11,14 +11,6 @@ enable_testing()
set(base_dir ${CMAKE_SOURCE_DIR}/../..)
-macro(cmake_to_native_path cmake_path native_path)
- if(WIN32)
- string(REPLACE "/" "\\" ${native_path} "${cmake_path}")
- else()
- set(${native_path} "${cmake_path}")
- endif()
-endmacro()
-
set(files_to_configure
bin/bbackupd/bbackupd-config
bin/bbstored/bbstored-certs
@@ -402,6 +394,6 @@ if(READLINE_FOUND)
endif()
# Define the location of the Perl executable, needed by testbackupstorefix
-cmake_to_native_path("${PERL_EXECUTABLE}" perl_executable_native)
+file(TO_NATIVE_PATH "${PERL_EXECUTABLE}" perl_executable_native)
string(REPLACE "\\" "\\\\" perl_path_escaped ${perl_executable_native})
target_compile_definitions(test_backupstorefix PRIVATE -DPERL_EXECUTABLE="${perl_path_escaped}")