i007.cc

i007.cc

优先队列-降维打击

vcpkg环境设置

vcpkg安装到linux平台

推荐使用Ubuntu 64位系统,以下以安装到/home/will/github目录为例

1.在github上获取vcpkg

使用ssh方式:

git clone [email protected]:microsoft/vcpkg.git

或者使用https方式

git clone https://github.com/microsoft/vcpkg.git

2.编译vcpkg

./bootstrap-vcpkg.sh

3.设置vcpkg软链接

ln -s /home/will/github/vcpkg ~/.vcpkg
ln -s /home/will/github/vcpkg/vcpkg /usr/local/bin/vcpkg
ln -s /home/will/.vcpkg/installed/x64-linux/tools/protobuf/protoc /usr/local/bin/protoc

vcpkg安装到Windows平台

推荐使用Win10-64位系统,以下以安装到D:\github目录为例

1.在github上获取vcpkg

使用ssh方式:

git clone [email protected]:microsoft/vcpkg.git

或者使用https方式

git clone https://github.com/microsoft/vcpkg.git

2.编译vcpkg

./bootstrap-vcpkg.bat

3.设置环境变量

变量名:VCPKG_DEFAULT_TRIPLET 
变量值:x64-windows

4.添加路径

D:\github\vcpkg
D:\github\vcpkg\installed\x64-windows\tools\protobuf

5.安装到vs2019

vcpkg integrate install

vcpkg使用

获取第三方库:

vcpkg install asio curl cxxopts fmt jemalloc jsoncpp libmariadb openssl protobuf spdlog tinyxml zlib

发表回复