I opened the vcxproj file with VS, build 2 succeedfully. But I can’t find any exe files. Where are they?
If I build Release version, under my Build folder, there is an empty Release sub-folder and a Win32 subfolder.
Under the Win32 subfolder, there is a Release sub-folder, with ALL_Build and Zero_Check subfolder. But no exe file in them.
Those build instructions are only accurate for linux. Visual Studio’s make tool is not called make but nmake and CMake does not generate a compatible makefile for it by default.
Instead of make, the correct, platform-independent command to build the project is:
cmake --build . --config Release
(replace Release by your actual build mode: Debug, Release, RelWithDebInfo, MinSizeRel)
If you use multi-configuration build toolchain (typical on Windows and macOS), then the binaries will be in build/ folder.
Firstly, in Build folder, I run:
cmake -DVTK_DIR:PATH=c:/bjVTK/lib/cmake/vtk-9.0 …
It generated CMakefiles folder and some vcxproj files.
Secondly, I run:
cmake --build . --config Release
It generated Release folder and Win32 folder. Still no where to find an exe file. It looks like the result is the same as opening the vcxproj file and build within VS. I was expecting to build within VS.
The other thing is I only compiled VTK into c:/bjVTK, but not installed it. Because when I try to build the Install target, it failed to copy files to c:/program files (x86) folder due to no access right.
I also put c:/bjVTK/bin into PATH.
@amaclean Using cmake-gui, I set VTK_DIR to C:/bjVTK/lib/cmake/vtk-9.0
the error message is:
Skipping ReadAllUnstructuredGridTypes: Could not find the VTK package with the following required components: RenderingContextOpenGL2.