VTK failed to cmake on windows
Environment: Windows Server 2016 + VS2017 VTK master branch latest srouce code
VTK failed to cmake due to No target "VTK::vtkpython" on windows. It can be reproduce on latest commit and can be first reproduced on commit 7c11a94f . Could you please help take a look at this? Thanks in advance!
Steps to reproduce the behavior:
- git clone https://gitlab.kitware.com/vtk/vtk.git D:\VTK\src
- Open a VS 2017 x86 command prompt and browse to D:\VTK
- mkdir build_x86 && pushd build_x86
- cmake -G "Visual Studio 15 2017" -DCMAKE_SYSTEM_VERSION=10.0.17134.0 -DBUILD_SHARED_LIBS=OFF -DBUILD_TESTING=ON -DBUILD_EXAMPLES=OFF -VTK_IGNORE_CMAKE_CXX11_CHECKS=TRUE ..\src
Error Message:
CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.13/Modules/ExternalData.cmake:334 (add_test):
Error evaluating generator expression:
$<TARGET_FILE:VTK::vtkpython>
No target "VTK::vtkpython"
Call Stack (most recent call first):
CMake/vtkModuleTesting.cmake:591 (ExternalData_add_test)
Filters/FlowPaths/Testing/Python/CMakeLists.txt:1 (vtk_add_test_python)
CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.13/Modules/ExternalData.cmake:334 (add_test):
Error evaluating generator expression:
$<TARGET_FILE:VTK::vtkpython>
No target "VTK::vtkpython"
Call Stack (most recent call first):
CMake/vtkModuleTesting.cmake:591 (ExternalData_add_test)
Filters/FlowPaths/Testing/Python/CMakeLists.txt:1 (vtk_add_test_python)
CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.13/Modules/ExternalData.cmake:334 (add_test):
Error evaluating generator expression:
$<TARGET_FILE:VTK::vtkpython>
No target "VTK::vtkpython"
Call Stack (most recent call first):
CMake/vtkModuleTesting.cmake:591 (ExternalData_add_test)
Filters/FlowPaths/Testing/Python/CMakeLists.txt:1 (vtk_add_test_python)
CMake Error at C:/Program Files (x86)/CMake/share/cmake-3.13/Modules/ExternalData.cmake:334 (add_test):
Error evaluating generator expression:
$<TARGET_FILE:VTK::vtkpython>
No target "VTK::vtkpython"
Call Stack (most recent call first):
CMake/vtkModuleTesting.cmake:591 (ExternalData_add_test)
Filters/FlowPaths/Testing/Python/CMakeLists.txt:1 (vtk_add_test_python)
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:
BUILD_EXAMPLES
-- Build files have been written to: D:/VTK/build_x86
[command took 244 seconds]
Edited by Mathieu Westphal (Kitware)