PS D:\proj\build> cmake .. -- Building for: Visual Studio 172022 -- Selecting Windows SDK version 10.0.22000.0 to target Windows 10.0.19045. -- The C compiler identification is MSVC 19.36.32534.0 -- The CXX compiler identification is MSVC 19.36.32534.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: E:/VS2022/VC/Tools/MSVC/14.36.32532/bin/Hostx64/x64/cl.exe - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: E:/VS2022/VC/Tools/MSVC/14.36.32532/bin/Hostx64/x64/cl.exe - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Configuring done (7.5s) -- Generating done (0.1s) -- Build files have been written to: D:/proj/build
输入命令cmake --build .编译:
PS D:\proj\build> cmake --build . MSBuild version 17.6.3+07e294721 for .NET Framework
1>Checking Build System Building Custom Rule D:/proj/CMakeLists.txt main.cpp win32.vcxproj -> D:\proj\build\Debug\win32.exe Building Custom Rule D:/proj/CMakeLists.txt