Skip to content

Update README.md

Update README.md #69

Workflow file for this run

name: Windows Build
on: [push]
env:
CCACHE_DIR: ~/.ccache
QT_VERSION: '5.14.2'
CACHE_VERSION: 1
GEODIFF_VERSION: 1.0.6
INPUT_VERSION: 'master'
concurrency:
group: ci-${{github.ref}}-windows
cancel-in-progress: true
jobs:
windows_build:
if: ( github.repository == 'MerginMaps/mergin-cpp-client' )
runs-on: windows-latest
steps:
- name: install deps
run: |
C:/vcpkg/vcpkg install sqlite3[rtree,fts3,json1] --triplet x64-windows-static
C:/vcpkg/vcpkg integrate install
dir "C:/vcpkg/packages/sqlite3_x64-windows-static/include"
dir "C:/vcpkg/packages/sqlite3_x64-windows-static/lib/"
- name: Checkout mergin-cpp-client
uses: actions/checkout@v2
with:
path: mergin-cpp-client
- name: Checkout input
uses: actions/checkout@v2
with:
ref: ${{ env.INPUT_VERSION }}
repository: MerginMaps/input
path: input
- name: Checkout geodiff
uses: actions/checkout@v2
with:
ref: ${{ env.GEODIFF_VERSION }}
repository: MerginMaps/geodiff
path: geodiff
- name: Cache Qt
id: cache-qt
uses: pat-s/[email protected]
with:
path: ${{ github.workspace }}/Qt
key: ${{ runner.os }}-QtCache-v1-${{ env.QT_VERSION }}-${{ env.CACHE_VERSION }}
- name: Install Qt
uses: jurplel/install-qt-action@v2
with:
version: ${{ env.QT_VERSION }}
dir: ${{ github.workspace }}
cached: ${{ steps.cache-qt.outputs.cache-hit }}
- name: Setup cmake
uses: jwlawson/[email protected]
- name: build geodiff
shell: pwsh
run: |
$ErrorActionPreference = 'continue'
function exec
{
param ( [ScriptBlock] $ScriptBlock )
& $ScriptBlock 2>&1 | ForEach-Object -Process { "$_" }
if ($LastExitCode -ne 0) { exit $LastExitCode }
}
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -arch=x64
cd $env:GITHUB_WORKSPACE
mkdir build-geodiff
cd build-geodiff
exec { cmake -G "Visual Studio 17 2022" -A x64 -DCMAKE_TOOLCHAIN_FILE=C:/vcpkg/scripts/buildsystems/vcpkg.cmake -DSQLite3_INCLUDE_DIR=C:/vcpkg/packages/sqlite3_x64-windows-static/include -DSQLite3_LIBRARY=C:/vcpkg/packages/sqlite3_x64-windows-static/lib/sqlite3.lib -DENABLE_TESTS=ON -DWITH_POSTGRESQL=FALSE -DBUILD_STATIC=ON -DBUILD_SHARED=OFF ../geodiff/geodiff }
exec { cmake --build . --config Release }
- name: build mergin-cpp-client
shell: cmd
run: |
copy mergin-cpp-client\scripts\ci\config.pri mergin-cpp-client\src\config.pri
mkdir build-mergin-cpp-client
cd build-mergin-cpp-client
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -arch=x64
qmake ..\mergin-cpp-client\src\client.pro CONFIG+=release CONFIG+=static
nmake release
- name: create release folder
shell: cmd
run: |
mkdir rel
cd rel
copy ..\build-mergin-cpp-client\release\mergin.exe mergin.exe
copy "C:\Program Files\OpenSSL\bin\libcrypto-1_1-x64.dll" libcrypto-1_1-x64.dll
copy "C:\Program Files\OpenSSL\bin\libssl-1_1-x64.dll" libssl-1_1-x64.dll
call "C:\Program Files\Microsoft Visual Studio\2022\Enterprise\Common7\Tools\VsDevCmd.bat" -arch=x64
windeployqt --release mergin.exe
dir
- name: archive release mergin
uses: actions/upload-artifact@v2
with:
name: mergin-cpp-client
path: |
rel