Tested with Visual Studio 2019/2022 and Windows 10/11
please first install Git and CMake
and then clone vcpkg package manager by git:
git clone https://github.com/Microsoft/vcpkg.git
cd vcpkg
bootstrap-vcpkg.bat
Install vcpkg package manager to build required libraries:
vcpkg install glm:x64-windows
vcpkg integrate install
finish step you can use "cmake" create project file with vcpkg toolchain:
cmake . -DCMAKE_TOOLCHAIN_FILE=\????\vcpkg\scripts\buildsystems\vcpkg.cmake
or use "cmake-gui" with "Specify toolchain file for cross-compiling."
please disable the "VULKAN_SUPPORT" option in CMake.
以下在Windows 10/11以及Visual Studio 2019/2022下测试通过
然后使用git安装vcpkg package manager
git clone https://github.com/Microsoft/vcpkg.git
cd vcpkg
bootstrap-vcpkg.bat
接着使用vcpkg package manager来安装我们所需要的第三方依赖库:
vcpkg install glm:x64-windows
vcpkg integrate install
最后你就可以使用CMake创建工程文件了:
cmake . -DCMAKE_TOOLCHAIN_FILE=\????\vcpkg\scripts\buildsystems\vcpkg.cmake
或是使用cmake-gui以图形界面形式创建,但请在第一个界面选择“Specify toolchain file for cross-compiling”并指定使用vcpkg.cmake做为工具链。
如出现关于Vulkan的报错,请在CMAKE中关掉VULKAN_SUPPORT选项