aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorsaturneric <[email protected]>2024-12-01 00:21:30 +0000
committersaturneric <[email protected]>2024-12-01 00:21:30 +0000
commite526e0843f1f521efe1cc8c249500522a73c03ae (patch)
treeed1edc42e9cc2f2f75fb84186ab11064077e2233
parentfix: solve build issue on windows (diff)
downloadGpgFrontend-dev/2.1.5/mingw.tar.gz
GpgFrontend-dev/2.1.5/mingw.zip
feat: improve windows release structure at nightly builddev/2.1.5/mingw
-rw-r--r--.github/workflows/testing-nightly.yml79
1 files changed, 53 insertions, 26 deletions
diff --git a/.github/workflows/testing-nightly.yml b/.github/workflows/testing-nightly.yml
index aabaaa35..a7e5dd8a 100644
--- a/.github/workflows/testing-nightly.yml
+++ b/.github/workflows/testing-nightly.yml
@@ -33,6 +33,7 @@ on:
env:
BUILD_TYPE: Release
+ GNUPG_VERSION: "2.4.7"
jobs:
build:
@@ -166,16 +167,6 @@ jobs:
cd ${{github.workspace}}
if: matrix.os == 'ubuntu-20.04'
- - name: Build GpgME (Windows)
- shell: msys2 {0}
- run: |
- git clone --depth 1 --branch fix/1.18.0 https://git.bktus.com/GpgFrontend/gpgme.git ${{github.workspace}}/third_party/gpgme
- cd ${{github.workspace}}/third_party/gpgme
- ./autogen.sh
- ./configure --enable-maintainer-mode --enable-languages=cpp --disable-gpg-test && make -j4
- make install
- if: matrix.os == 'windows-2019'
-
- name: Build googletest (Linux)
run: |
git clone --depth 1 --branch v1.15.0 https://github.com/google/googletest.git ${{github.workspace}}/third_party/googletest
@@ -196,7 +187,7 @@ jobs:
- name: Build & Install Full SDK (Windows)
shell: msys2 {0}
run: |
- cygpath -u ${{github.workspace}}
+ cd $(cygpath -u "${{github.workspace}}")
mkdir build-full-sdk && cd build-full-sdk
cmake -G Ninja -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DGPGFRONTEND_BUILD_TYPE_FULL_SDK=ON -DCMAKE_INSTALL_PREFIX=$MSYSTEM_PREFIX ..
cmake --build . --config ${{env.BUILD_TYPE}} -- -j 4
@@ -213,7 +204,7 @@ jobs:
- name: Build Integrated Modules (Windows)
shell: msys2 {0}
run: |
- cygpath -u ${{github.workspace}}
+ cd $(cygpath -u "${{github.workspace}}")
cd modules
mkdir build && cd build
cmake -G Ninja -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DGPGFRONTEND_BUILD_TYPE_STABLE=ON -DCMAKE_INSTALL_PREFIX=./artifacts ..
@@ -254,10 +245,10 @@ jobs:
ditto -c -k --keepParent ${{github.workspace}}/build/package/GpgFrontend.app ${{github.workspace}}/build/GpgFrontend.app.zip
hdiutil create ${{github.workspace}}/build/tmp.dmg -ov \
-volname "GpgFrontend" -fs HFS+ -srcfolder ${{github.workspace}}/build/package/
- mkdir ${{github.workspace}}/build/final-artifact
- create-dmg --codesign "${{secrets.GPGFRONTEND_XOCDE_CODE_SIGN_IDENTITY}}" --volicon "${{github.workspace}}/resource/lfs/icns/GpgFrontend.icns" --volname GpgFrontend --app-drop-link 600 185 --window-size 800 400 ${{github.workspace}}/build/final-artifact/GpgFrontend.dmg ${{github.workspace}}/build/package/GpgFrontend.app
- mv ${{github.workspace}}/build/final-artifact/GpgFrontend.dmg \
- ${{github.workspace}}/build/final-artifact/GpgFrontend-${{env.sha_short}}.dmg
+ mkdir ${{github.workspace}}/build/upload-artifact
+ create-dmg --codesign "${{secrets.GPGFRONTEND_XOCDE_CODE_SIGN_IDENTITY}}" --volicon "${{github.workspace}}/resource/lfs/icns/GpgFrontend.icns" --volname GpgFrontend --app-drop-link 600 185 --window-size 800 400 ${{github.workspace}}/build/upload-artifact/GpgFrontend.dmg ${{github.workspace}}/build/package/GpgFrontend.app
+ mv ${{github.workspace}}/build/upload-artifact/GpgFrontend.dmg \
+ ${{github.workspace}}/build/upload-artifact/GpgFrontend-${{env.sha_short}}.dmg
mv ${{github.workspace}}/build/GpgFrontend.app.zip \
${{github.workspace}}/build/GpgFrontend-${{env.sha_short}}.zip
if: matrix.os == 'macos-12'
@@ -283,8 +274,8 @@ jobs:
- name: Copy Modules & Package App Image (Linux)
run: |
cmake -E copy_directory ${{github.workspace}}/modules/build/artifacts/modules ${{github.workspace}}/build/artifacts/AppDir/usr/modules
- mkdir ${{github.workspace}}/build/final-artifact
- cd ${{github.workspace}}/build/final-artifact
+ mkdir ${{github.workspace}}/build/upload-artifact
+ cd ${{github.workspace}}/build/upload-artifact
wget -c -nv https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage
chmod u+x linuxdeployqt-continuous-x86_64.AppImage
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
@@ -296,7 +287,7 @@ jobs:
- name: Configure CMake & Build Application (Windows)
shell: msys2 {0}
run: |
- cygpath -u ${{github.workspace}}
+ cd $(cygpath -u "${{github.workspace}}")
mkdir build && cd build
cmake -G Ninja -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} -DGPGFRONTEND_BUILD_TYPE_ONLY_APPLICATION=ON ..
cmake --build . --config ${{env.BUILD_TYPE}} -- -j 4
@@ -308,38 +299,74 @@ jobs:
echo "BUILD_TYPE_LOWER=$("${{env.BUILD_TYPE}}".ToLower())" >> $env:GITHUB_ENV
if: matrix.os == 'windows-2019'
+ - name: Download GnuPG Binary Release (Windows)
+ shell: msys2 {0}
+ run: |
+ export URL="https://ftp.bktus.com/GnuPG/${{env.GNUPG_VERSION}}"
+ export FILE="gnupg.zip"
+ export CHECKSUM_FILE="SHA256SUMS.txt"
+
+ cd $(cygpath -u "${{github.workspace}}")
+
+ mkdir -p build/downloads
+ curl -o build/downloads/$FILE $URL/$FILE
+ curl -o build/downloads/$CHECKSUM_FILE $URL/$CHECKSUM_FILE
+
+ CHECKSUM=$(grep "$FILE" build/downloads/$CHECKSUM_FILE | awk '{print $1}')
+ ACTUAL_CHECKSUM=$(sha256sum build/downloads/$FILE | awk '{print $1}')
+ echo "Expected Checksum: $CHECKSUM"
+ echo "Actual Checksum: $ACTUAL_CHECKSUM"
+ if [ "$CHECKSUM" != "$ACTUAL_CHECKSUM" ]; then
+ echo "Checksum verification failed!" >&2
+ exit 1
+ fi
+
+ mkdir -p build/artifacts
+ unzip build/downloads/$FILE -d build/artifacts/
+ ls -l build/artifacts/
+ if: matrix.os == 'windows-2019'
+
- name: Copy Modules & Package (Windows)
shell: msys2 {0}
run: |
- cygpath -u ${{github.workspace}}
+ cd $(cygpath -u "${{github.workspace}}")
+ cp PrivacyPolicy.md build/artifacts/
+ cp README.md build/artifacts/
+ cp SECURITY.md build/artifacts/
+ cp TRANSLATORS build/artifacts/
+ cp COPYING build/artifacts/
+ cp gpgfrontend.ico build/artifacts/bin/GpgFrontend.ico
+ touch build/artifacts/bin/PORTABLE.txt
mkdir -p build/artifacts/modules
cp -r modules/build/artifacts/bin/* build/artifacts/modules
cd build
- windeployqt-qt6 --no-translations --force ./artifacts/GpgFrontend.exe
- mkdir final-artifact
+ windeployqt-qt6 --no-translations --force ./artifacts/bin/libgpgfrontend_core.dll
+ windeployqt-qt6 --no-translations --force ./artifacts/bin/libgpgfrontend_ui.dll
+ windeployqt-qt6 --no-translations --force ./artifacts/bin/GpgFrontend.exe
+ mkdir upload-artifact
cd artifacts
- zip -r ../final-artifact/GpgFrontend-${{env.SHORT_SHA}}-x86_64.zip *
+ zip -r ../upload-artifact/GpgFrontend-${{env.SHORT_SHA}}-x86_64.zip *
if: matrix.os == 'windows-2019'
- name: Upload Artifact (Linux)
uses: actions/upload-artifact@master
with:
name: gpgfrontend-${{matrix.os}}-${{env.BUILD_TYPE_LOWER}}-${{env.SHORT_SHA}}
- path: ${{github.workspace}}/build/final-artifact/Gpg_Frontend*.AppImage*
+ path: ${{github.workspace}}/build/upload-artifact/Gpg_Frontend*.AppImage*
if: matrix.os == 'ubuntu-20.04'
- name: Upload Artifact (macOS)
uses: actions/upload-artifact@master
with:
name: gpgfrontend-${{matrix.os}}-${{env.BUILD_TYPE_LOWER}}-${{env.SHORT_SHA}}
- path: ${{github.workspace}}/build/final-artifact/*
+ path: ${{github.workspace}}/build/upload-artifact/*
if: matrix.os == 'macos-12'
- name: Upload Artifact (Windows)
uses: actions/upload-artifact@master
with:
name: gpgfrontend-${{matrix.os}}-${{env.BUILD_TYPE_LOWER}}-${{env.SHORT_SHA}}
- path: ${{github.workspace}}/build/final-artifact/*
+ path: ${{github.workspace}}/build/upload-artifact/*
if: matrix.os == 'windows-2019'
release:
needs: build