Skip to content

build-win64

build-win64 #3

Workflow file for this run

name: build-win64
on:
workflow_dispatch:
env:
REF_TAG: v1.1.1
jobs:
user-manual:
uses: ./.github/workflows/user-manual.yml
with:
runs-on: ubuntu-latest
build:
runs-on: windows-2022
needs: user-manual
env:
# Customize the CMake build type here (Release, Debug, RelWithDebInfo, etc.)
BUILD_TYPE: RelWithDebInfo
steps:
- run: git config --global core.autocrlf input
- uses: actions/checkout@v4
with:
repository: ctlcltd/e2-sat-editor
ref: ${{ env.REF_TAG }}
path: e2-sat-editor
- name: Patch e2se_defs.h
working-directory: ${{github.workspace}}/e2-sat-editor/src
shell: pwsh
run: |
head -n 22 e2se_defs.h > e2se_defs.h.new
echo "#define E2SE_PORTABLE" >> e2se_defs.h.new
tail -n +24 e2se_defs.h >> e2se_defs.h.new
mv e2se_defs.h e2se_defs.h.bak
mv e2se_defs.h.new e2se_defs.h
- name: Setup MSYS2
uses: msys2/setup-msys2@v2
with:
pacboy: >-
cc:x cmake:x ninja:x qt6-base:x qt6-translations:x curl:x
- name: Configure CMake
working-directory: ${{github.workspace}}/e2-sat-editor/src
shell: msys2 {0}
run: |
cmake \
-G Ninja \
-B build \
-DCMAKE_BUILD_TYPE=${{ env.BUILD_TYPE }}
- name: Build
working-directory: ${{github.workspace}}/e2-sat-editor/src
shell: msys2 {0}
run: cmake --build build --config ${{ env.BUILD_TYPE }}
- name: Download user-manual artifact
uses: actions/download-artifact@v4
with:
name: user-manual
path: user-manual
run-id: ${{ needs.user-manual.outputs.run-id }}
- name: Deploy
working-directory: ${{github.workspace}}/e2-sat-editor/src
continue-on-error: true
shell: msys2 {0}
run: |
DESTDIR=../AppDir ninja -C build install
# run windeployqt
#windeployqt6.exe "AppDir/Program Files (x86)/e2-sat-editor/bin/e2-sat-editor.exe"
# package
mkdir -p ../artifact/{cli,user-manual}
cp ../README.md ../artifact/
cp COPYING ../artifact/
mv "AppDir/Program Files (x86)/e2-sat-editor/bin/e2-sat-editor.exe" ../artifact/
mv "AppDir/Program Files (x86)/e2-sat-editor/bin/e2se-cli.exe" ../artifact/cli/
mv ${{github.workspace}}/user-manual ../artifact/
# - name: Test
# working-directory: ${{github.workspace}}/e2-sat-editor/artifact
# continue-on-error: true
# timeout-minutes: 1
# run: |
# DEBUG=1 QT_QPA_PLATFORM=minimal e2-sat-editor.exe
- name: Upload Artifact
uses: actions/upload-artifact@v4
with:
path: ${{github.workspace}}/e2-sat-editor/artifact