vcpkg使用
下载
vcpkg官网
安装
pthread安装参考
Vcpkg C/C++库管理工具安装和使用教程(链接VS2019)
# 1. windows+R -> cmd
# 2. cd -> vcpkg 路径
# 3. 运行
bootstrap-vcpkg.bat #自动更新vcpkg.exe
# 如何提示下载慢或失败,请根据提示的网站手动下载
# 4. 测试
vcpkg.exe search #如何有安装包提示,表示正常
# 5. 安装vc包
vcpkg.exe install pthread #安装pthread
# 6 将pthread配置到 Visual Studio 中使用
vcpkg integrate installC:\vcpkg>vcpkg integrate install
Applied user-wide integration for this vcpkg root.
CMake projects should use: "-DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake"All MSBuild C++ projects can now #include any installed libraries. Linking will be handled automatically. Installing new libraries will make them instantly available.
# 提示表示安装成功