-
Notifications
You must be signed in to change notification settings - Fork 50
Building_PCMan
holishing edited this page May 23, 2020
·
19 revisions
-
安裝 Visual Studio 2017/2019 (Community 即可)
- 請至官方網站下載: https://www.visualstudio.com/
- 安裝過程詢問到要安裝那些模組時,將C++有關的套件選項都勾起來安裝,依照安裝程式導引安裝完成
-
建立一個本機資料夾可以放 git repository,以下將資料夾路徑代稱為
本機Git資料夾
-
git clone pcman-windows (https://github.com/pcman-bbs/pcman-windows.git) 到
本機Git資料夾\pcman-windows
- 可以用 git 的
git clone
指令,或者 git 的相關 GUI 軟體的 clone 功能
- 可以用 git 的
-
git clone vcpkg (https://github.com/Microsoft/vcpkg) 到
本機git資料夾\vcpkg
- clone完成後,依照官方頁面教學,點兩下執行或開 cmd 在底下輸入檔名執行 vcpkg\bootstrap-vcpkg.bat
- 執行完成後會出現
vcpkg\vcpkg.exe
- 開啟cmd,執行
cd /d 本機Git資料夾\vcpkg
,再執行vcpkg integrate install
- 正確會印出訊息
Applied user-wide integration for this vcpkg root.
- 如果出現
Warning: integration was not applied
,則將整個vcpkg資料夾複製到C:\
,再執行vcpkg integrate install
。後面步驟的vcpkg路徑都要改成C:\vcpkg
[註1]
- 正確會印出訊息
- 執行
vcpkg install cpprestsdk[default-features,websockets]:x86-windows
以安裝相關套件
-
建置執行 PCMan 專案
- 用 visual studio 開啟
本機Git資料夾\pcman-windows\PCMan.sln
- 開啟後等待 visual studio 載入,等到左下角訊息不再變動
- 在 Combo 專案 > 右鍵 > Build(建置) ,等待建置成功
- 在 Lite 專案 > 右鍵 > Build(建置) ,等待建置成功
- 在 Lite 或 Combo 專案 > 右鍵 > Set as StartUp Project(設定為起始專案) > 按下 F5 , 即可執行出現 PCMan 的程式畫面
- 用 visual studio 開啟
.
[註1] : https://github.com/Microsoft/vcpkg/issues/5956 提到
I have reinstalled vcpkg directly to the c-drive and now it is working, even if I don't know why. Thank you for the support.