Vcpkg是一個微軟C++ 團隊開發(fā)的在 Windows 上運行的 C/C++ 項目包管理工具,可以幫助您在 Windows 平臺上獲取 C 和 C++ 庫,極大地簡化三方庫的獲取、安裝、使用和部署流程。
vcpkg 整合了 git,構建系統(tǒng)整合的 CMake,而絕大多數(shù)的 C++ 項目都可以直接或者間接的方式使用 CMake創(chuàng)建原生項目文件并構建.
vcpkg遵循一下原則:
開放源碼
無需安裝
支持重發(fā)構建
自定義生成
社區(qū)參與貢獻
端口集成(與 BSD Ports 機制類似)
安裝教程
首先,我們的windows系統(tǒng)必須安裝有下列軟件
Visual Studio 2015 Update 3 or
Visual Studio 2017
CMake 3.8.0 or higher (note: downloaded automatically if not found)
git.exe available in your path
然后,我們在windows命令行終端上運行:
d:\git> git clone https://github.com/Microsoft/vcpkg
d:\git> cd vcpkg
d:\git\vcpkg> .\bootstrap-vcpkg.bat
d:\git\vcpkg> .\vcpkg integrate install