diff options
author | Marc Chevrier <marc.chevrier@sap.com> | 2018-04-05 10:09:53 (GMT) |
---|---|---|
committer | Marc Chevrier <marc.chevrier@sap.com> | 2018-04-05 10:09:53 (GMT) |
commit | 38dcdd76413c012a569eccb67c195f1d6840e2b8 (patch) | |
tree | 71a140462721242f9ff83ea0cd62777e3c101a99 /Tests/UseSWIG/ModuleVersion2 | |
parent | 3201e4c156fcf79a7c29a73430e72b1bcd43cedc (diff) | |
download | CMake-38dcdd76413c012a569eccb67c195f1d6840e2b8.zip CMake-38dcdd76413c012a569eccb67c195f1d6840e2b8.tar.gz CMake-38dcdd76413c012a569eccb67c195f1d6840e2b8.tar.bz2 |
UseSWIG: Ensure tests are usable in multi-config mode.
Fixes: #17875
Diffstat (limited to 'Tests/UseSWIG/ModuleVersion2')
-rw-r--r-- | Tests/UseSWIG/ModuleVersion2/CMakeLists.txt | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/Tests/UseSWIG/ModuleVersion2/CMakeLists.txt b/Tests/UseSWIG/ModuleVersion2/CMakeLists.txt index 92cbcd3..3f9d363 100644 --- a/Tests/UseSWIG/ModuleVersion2/CMakeLists.txt +++ b/Tests/UseSWIG/ModuleVersion2/CMakeLists.txt @@ -10,6 +10,12 @@ include(${SWIG_USE_FILE}) find_package(Python2 REQUIRED COMPONENTS Interpreter Development) find_package(Python3 REQUIRED COMPONENTS Interpreter Development) +if (WIN32) + set (PS $<SEMICOLON>) +else() + set (PS ":") +endif() + set (UseSWIG_MODULE_VERSION 2) unset(CMAKE_SWIG_FLAGS) @@ -41,12 +47,6 @@ set_target_properties (example2 PROPERTIES target_link_libraries(example2 PRIVATE Python3::Python) -if (WIN32) - set (PS $<SEMICOLON>) -else() - set (PS ":") -endif() - add_test (NAME ModuleVersion2.example1 COMMAND "${CMAKE_COMMAND}" -E env "PYTHONPATH=$<TARGET_PROPERTY:example1,SWIG_SUPPORT_FILES_DIRECTORY>${PS}$<TARGET_FILE_DIR:example1>" "${Python2_EXECUTABLE}" "${CMAKE_CURRENT_SOURCE_DIR}/../runme.py") |