mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-04-29 23:09:44 -04:00
Moves vcpkg list to a text file and updates the appveyor job and readme to use it.
Github-Pull: #17416
Rebased-From: 29eb039252
This commit is contained in:
parent
cd7b3b254a
commit
b0f9b8e648
3 changed files with 19 additions and 16 deletions
|
@ -7,7 +7,6 @@ clone_depth: 5
|
||||||
environment:
|
environment:
|
||||||
APPVEYOR_SAVE_CACHE_ON_ERROR: true
|
APPVEYOR_SAVE_CACHE_ON_ERROR: true
|
||||||
CLCACHE_SERVER: 1
|
CLCACHE_SERVER: 1
|
||||||
PACKAGES: berkeleydb boost-filesystem boost-multi-index boost-signals2 boost-test boost-thread libevent openssl rapidcheck zeromq double-conversion
|
|
||||||
PATH: 'C:\Python37-x64;C:\Python37-x64\Scripts;%PATH%'
|
PATH: 'C:\Python37-x64;C:\Python37-x64\Scripts;%PATH%'
|
||||||
PYTHONUTF8: 1
|
PYTHONUTF8: 1
|
||||||
QT_DOWNLOAD_URL: 'https://github.com/sipsorcery/qt_win_binary/releases/download/v1.4/Qt5.9.8_x64_static_vs2019.zip'
|
QT_DOWNLOAD_URL: 'https://github.com/sipsorcery/qt_win_binary/releases/download/v1.4/Qt5.9.8_x64_static_vs2019.zip'
|
||||||
|
@ -15,7 +14,7 @@ environment:
|
||||||
QT_LOCAL_PATH: 'C:\Qt5.9.8_x64_static_vs2019'
|
QT_LOCAL_PATH: 'C:\Qt5.9.8_x64_static_vs2019'
|
||||||
VCPKG_INSTALL_PATH: 'C:\tools\vcpkg\installed'
|
VCPKG_INSTALL_PATH: 'C:\tools\vcpkg\installed'
|
||||||
cache:
|
cache:
|
||||||
- C:\tools\vcpkg\installed
|
- C:\tools\vcpkg\installed -> build_msvc\vcpkg-packages.txt
|
||||||
- C:\Users\appveyor\clcache -> .appveyor.yml, build_msvc\**, **\Makefile.am, **\*.vcxproj.in
|
- C:\Users\appveyor\clcache -> .appveyor.yml, build_msvc\**, **\Makefile.am, **\*.vcxproj.in
|
||||||
- C:\Qt5.9.8_x64_static_vs2019
|
- C:\Qt5.9.8_x64_static_vs2019
|
||||||
install:
|
install:
|
||||||
|
@ -23,25 +22,27 @@ install:
|
||||||
# Disable zmq test for now since python zmq library on Windows would cause Access violation sometimes.
|
# Disable zmq test for now since python zmq library on Windows would cause Access violation sometimes.
|
||||||
# - cmd: pip install zmq
|
# - cmd: pip install zmq
|
||||||
# Powershell block below is to install the c++ dependencies via vcpkg. The pseudo code is:
|
# Powershell block below is to install the c++ dependencies via vcpkg. The pseudo code is:
|
||||||
# 1. If the vcpkg install directory exists assume dependencies are installed and do nothing. To
|
# 1. Check whether the vcpkg install directory exists (note that updating the vcpkg-packages.txt file
|
||||||
# force a fresh install of the packages delete the job's appveyor cache.
|
# will cause the appveyor cache rules to invalidate the directory)
|
||||||
# 2. Otherwise:
|
# 2. If the directory is missing:
|
||||||
# a. Update the vcpkg source (including port files) and build the vcpkg binary,
|
# a. Update the vcpkg source (including port files) and build the vcpkg binary,
|
||||||
# b. Install the required packages.
|
# b. Install the missing packages.
|
||||||
- ps: |
|
- ps: |
|
||||||
cd c:\tools\vcpkg
|
$env:PACKAGES = Get-Content -Path build_msvc\vcpkg-packages.txt
|
||||||
|
Write-Host "vcpkg list: $env:PACKAGES"
|
||||||
if(!(Test-Path -Path ($env:VCPKG_INSTALL_PATH))) {
|
if(!(Test-Path -Path ($env:VCPKG_INSTALL_PATH))) {
|
||||||
|
cd c:\tools\vcpkg
|
||||||
$env:GIT_REDIRECT_STDERR = '2>&1' # git is writing non-errors to STDERR when doing git pull. Send to STDOUT instead.
|
$env:GIT_REDIRECT_STDERR = '2>&1' # git is writing non-errors to STDERR when doing git pull. Send to STDOUT instead.
|
||||||
Add-Content "C:\tools\vcpkg\triplets\$env:PLATFORM-windows-static.cmake" "set(VCPKG_BUILD_TYPE release)"
|
|
||||||
git pull origin master
|
git pull origin master
|
||||||
.\bootstrap-vcpkg.bat
|
.\bootstrap-vcpkg.bat
|
||||||
|
Add-Content "C:\tools\vcpkg\triplets\$env:PLATFORM-windows-static.cmake" "set(VCPKG_BUILD_TYPE release)"
|
||||||
.\vcpkg install --triplet $env:PLATFORM-windows-static $env:PACKAGES.split() > $null
|
.\vcpkg install --triplet $env:PLATFORM-windows-static $env:PACKAGES.split() > $null
|
||||||
|
cd "$env:APPVEYOR_BUILD_FOLDER"
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
Write-Host "vcpkg packages already installed (to reinstall purge appveyor job's cache)."
|
Write-Host "required vcpkg packages already installed."
|
||||||
}
|
}
|
||||||
.\vcpkg integrate install
|
c:\tools\vcpkg\vcpkg integrate install
|
||||||
cd "$env:APPVEYOR_BUILD_FOLDER"
|
|
||||||
before_build:
|
before_build:
|
||||||
- ps: clcache -M 536870912
|
- ps: clcache -M 536870912
|
||||||
# Powershell block below is to download and extract the Qt static libraries. The pseudo code is:
|
# Powershell block below is to download and extract the Qt static libraries. The pseudo code is:
|
||||||
|
|
|
@ -56,11 +56,12 @@ Building
|
||||||
---------------------
|
---------------------
|
||||||
The instructions below use `vcpkg` to install the dependencies.
|
The instructions below use `vcpkg` to install the dependencies.
|
||||||
|
|
||||||
- Clone `vcpkg` from the [github repository](https://github.com/Microsoft/vcpkg) and install as per the instructions in the main README.md.
|
- Install [`vcpkg`](https://github.com/Microsoft/vcpkg).
|
||||||
- Install the required packages (replace x64 with x86 as required):
|
- Install the required packages (replace x64 with x86 as required). The list of required packages can be found in the `build_msvc\vcpkg-packages.txt` file. The PowerShell command below will work if run from the repository root directory and `vcpkg` is in the path. Alternatively the contents of the packages text file can be pasted in place of the `Get-Content` cmdlet.
|
||||||
|
|
||||||
```
|
```
|
||||||
PS >.\vcpkg install --triplet x64-windows-static boost-filesystem boost-signals2 boost-test libevent openssl zeromq berkeleydb rapidcheck double-conversion
|
PS >.\vcpkg install --triplet x64-windows-static $(Get-Content -Path build_msvc\vcpkg-packages.txt).split()
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
- Use Python to generate *.vcxproj from Makefile
|
- Use Python to generate *.vcxproj from Makefile
|
||||||
|
@ -74,13 +75,13 @@ The instructions below use `vcpkg` to install the dependencies.
|
||||||
- Build with Visual Studio 2017 or msbuild.
|
- Build with Visual Studio 2017 or msbuild.
|
||||||
|
|
||||||
```
|
```
|
||||||
msbuild /m bitcoin.sln /p:Platform=x64 /p:Configuration=Release /t:build
|
msbuild /m bitcoin.sln /p:Platform=x64 /p:Configuration=Release /p:PlatformToolset=v141 /t:build
|
||||||
```
|
```
|
||||||
|
|
||||||
- Build with Visual Studio 2019 or msbuild.
|
- Build with Visual Studio 2019 or msbuild.
|
||||||
|
|
||||||
```
|
```
|
||||||
msbuild /m bitcoin.sln /p:Platform=x64 /p:Configuration=Release /p:PlatformToolset=v142 /t:build
|
msbuild /m bitcoin.sln /p:Platform=x64 /p:Configuration=Release /t:build
|
||||||
```
|
```
|
||||||
|
|
||||||
AppVeyor
|
AppVeyor
|
||||||
|
|
1
build_msvc/vcpkg-packages.txt
Normal file
1
build_msvc/vcpkg-packages.txt
Normal file
|
@ -0,0 +1 @@
|
||||||
|
berkeleydb boost-filesystem boost-multi-index boost-signals2 boost-test boost-thread libevent openssl rapidcheck zeromq double-conversion
|
Loading…
Add table
Reference in a new issue