2020-04-21 08:53:37 +03:00
|
|
|
name: Build Check
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2023-03-19 06:30:11 +03:00
|
|
|
branches: [main]
|
2020-04-21 08:53:37 +03:00
|
|
|
pull_request:
|
2023-03-19 06:30:11 +03:00
|
|
|
branches: [main]
|
2020-04-21 08:53:37 +03:00
|
|
|
|
2023-04-08 06:42:23 +03:00
|
|
|
concurrency:
|
2023-04-09 02:48:40 +03:00
|
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
2023-04-08 06:42:23 +03:00
|
|
|
cancel-in-progress: true
|
|
|
|
|
2020-04-21 08:53:37 +03:00
|
|
|
jobs:
|
2020-04-24 06:33:54 +03:00
|
|
|
build-ubuntu:
|
2020-05-03 08:27:35 +03:00
|
|
|
name: ${{ matrix.config.name }}
|
|
|
|
runs-on: ${{ matrix.config.os }}
|
2020-04-24 06:33:54 +03:00
|
|
|
strategy:
|
2020-05-03 21:15:48 +03:00
|
|
|
fail-fast: false
|
2020-04-24 06:33:54 +03:00
|
|
|
matrix:
|
2020-05-03 08:27:35 +03:00
|
|
|
config:
|
|
|
|
- {
|
2022-10-03 00:35:25 +03:00
|
|
|
name: "Ubuntu 20.04 / Qt 5",
|
2022-10-02 23:23:48 +03:00
|
|
|
os: ubuntu-20.04,
|
2022-10-03 00:35:25 +03:00
|
|
|
qt_packages: "libqt5x11extras5-dev qt5-default qtwebengine5-dev",
|
2022-10-03 06:25:07 +03:00
|
|
|
configurePreset: "ninja-multi",
|
|
|
|
buildPreset: "ninja-multi-release"
|
2020-05-03 08:27:35 +03:00
|
|
|
}
|
|
|
|
- {
|
2022-10-03 00:35:25 +03:00
|
|
|
name: "Ubuntu 20.04 / Qt 5 / Portable",
|
2022-10-02 23:23:48 +03:00
|
|
|
os: ubuntu-20.04,
|
2022-10-03 00:35:25 +03:00
|
|
|
qt_packages: "libqt5x11extras5-dev qt5-default qtwebengine5-dev",
|
2022-10-03 06:25:07 +03:00
|
|
|
configurePreset: "ninja-multi-portable",
|
|
|
|
buildPreset: "ninja-multi-portable-release"
|
2020-05-03 08:27:35 +03:00
|
|
|
}
|
2022-10-03 00:35:25 +03:00
|
|
|
- {
|
|
|
|
name: "Ubuntu 22.04 / Qt 6",
|
|
|
|
os: ubuntu-22.04,
|
|
|
|
qt_packages: "libgl1-mesa-dev libqt6opengl6-dev qt6-base-private-dev qt6-webengine-dev qt6-webengine-dev-tools",
|
2022-10-03 06:25:07 +03:00
|
|
|
configurePreset: "ninja-multi",
|
|
|
|
buildPreset: "ninja-multi-release"
|
2022-10-03 00:35:25 +03:00
|
|
|
}
|
|
|
|
- {
|
|
|
|
name: "Ubuntu 22.04 / Qt 6 / Portable",
|
|
|
|
os: ubuntu-22.04,
|
|
|
|
qt_packages: "libgl1-mesa-dev libqt6opengl6-dev qt6-base-private-dev qt6-webengine-dev qt6-webengine-dev-tools",
|
2022-10-03 06:25:07 +03:00
|
|
|
configurePreset: "ninja-multi-portable",
|
|
|
|
buildPreset: "ninja-multi-portable-release"
|
2022-10-03 00:35:25 +03:00
|
|
|
}
|
|
|
|
|
2020-04-24 06:33:54 +03:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-09-05 05:16:25 +03:00
|
|
|
uses: actions/checkout@v4
|
2020-09-21 09:06:30 +03:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
2020-04-24 06:33:54 +03:00
|
|
|
|
|
|
|
- name: Install Dependencies
|
|
|
|
run: |
|
|
|
|
sudo apt-get -y -qq update
|
|
|
|
sudo apt-get -y -qq --no-install-recommends install \
|
|
|
|
cmake \
|
|
|
|
extra-cmake-modules \
|
|
|
|
libarchive-dev \
|
|
|
|
libsqlite3-dev \
|
2023-09-17 10:26:28 +03:00
|
|
|
libvulkan-dev \
|
2020-04-24 06:33:54 +03:00
|
|
|
libxcb-keysyms1-dev \
|
2020-05-17 16:56:03 +03:00
|
|
|
ninja-build \
|
2022-10-03 00:35:25 +03:00
|
|
|
${{ matrix.config.qt_packages }}
|
2020-04-24 06:33:54 +03:00
|
|
|
|
2020-05-17 16:56:03 +03:00
|
|
|
- name: Configure & Build
|
2022-10-03 06:25:07 +03:00
|
|
|
uses: lukka/run-cmake@v10
|
2020-05-17 16:56:03 +03:00
|
|
|
with:
|
2022-10-03 06:25:07 +03:00
|
|
|
configurePreset: ${{ matrix.config.configurePreset }}
|
|
|
|
buildPreset: ${{ matrix.config.buildPreset }}
|
2020-04-24 06:33:54 +03:00
|
|
|
|
2020-05-03 21:15:48 +03:00
|
|
|
build-windows:
|
|
|
|
name: ${{ matrix.config.name }}
|
|
|
|
runs-on: ${{ matrix.config.os }}
|
|
|
|
strategy:
|
|
|
|
fail-fast: false
|
|
|
|
matrix:
|
|
|
|
config:
|
|
|
|
- {
|
2022-10-02 22:04:33 +03:00
|
|
|
name: "Windows Server 2019 / Qt 5",
|
2020-05-03 21:15:48 +03:00
|
|
|
os: windows-2019,
|
2022-10-02 22:04:33 +03:00
|
|
|
qt_modules: "qtwebengine",
|
2022-10-02 23:23:48 +03:00
|
|
|
qt_version: "5.15.2",
|
2022-07-23 20:15:48 +03:00
|
|
|
configurePreset: "ninja-multi-vcpkg",
|
2023-04-29 07:24:55 +03:00
|
|
|
buildPreset: "ninja-multi-vcpkg-release",
|
|
|
|
publishArtifacts: false
|
2020-05-03 21:15:48 +03:00
|
|
|
}
|
|
|
|
- {
|
2022-10-02 22:04:33 +03:00
|
|
|
name: "Windows Server 2019 / Qt 5 / Portable",
|
2020-05-03 21:15:48 +03:00
|
|
|
os: windows-2019,
|
2022-10-02 22:04:33 +03:00
|
|
|
qt_modules: "qtwebengine",
|
2022-10-02 23:23:48 +03:00
|
|
|
qt_version: "5.15.2",
|
2022-10-02 22:04:33 +03:00
|
|
|
configurePreset: ninja-multi-vcpkg-portable,
|
2023-04-29 07:24:55 +03:00
|
|
|
buildPreset: ninja-multi-vcpkg-portable-release,
|
|
|
|
publishArtifacts: false
|
2022-10-02 22:04:33 +03:00
|
|
|
}
|
|
|
|
- {
|
|
|
|
name: "Windows Server 2022 / Qt 6",
|
|
|
|
os: windows-2022,
|
|
|
|
qt_modules: "qtwebengine qtwebchannel qtpositioning",
|
2023-09-10 23:01:29 +03:00
|
|
|
qt_version: "6.5.2",
|
2022-10-02 22:04:33 +03:00
|
|
|
configurePreset: ninja-multi-vcpkg,
|
2023-04-29 07:24:55 +03:00
|
|
|
buildPreset: ninja-multi-vcpkg-release,
|
|
|
|
publishArtifacts: true
|
2022-10-02 22:04:33 +03:00
|
|
|
}
|
|
|
|
- {
|
|
|
|
name: "Windows Server 2022 / Qt 6 / Portable",
|
|
|
|
os: windows-2022,
|
|
|
|
qt_modules: "qtwebengine qtwebchannel qtpositioning",
|
2023-09-10 23:01:29 +03:00
|
|
|
qt_version: "6.5.2",
|
2022-10-02 22:04:33 +03:00
|
|
|
configurePreset: ninja-multi-vcpkg-portable,
|
2023-04-29 07:24:55 +03:00
|
|
|
buildPreset: ninja-multi-vcpkg-portable-release,
|
|
|
|
publishArtifacts: true
|
2020-05-03 21:15:48 +03:00
|
|
|
}
|
|
|
|
|
2022-07-23 20:15:48 +03:00
|
|
|
env:
|
|
|
|
VCPKG_DEFAULT_TRIPLET: x64-windows-release
|
|
|
|
|
2020-05-03 21:15:48 +03:00
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-09-05 05:16:25 +03:00
|
|
|
uses: actions/checkout@v4
|
2020-09-21 09:06:30 +03:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
2020-05-03 21:15:48 +03:00
|
|
|
|
|
|
|
- name: Prepare vcpkg
|
2023-04-08 07:34:03 +03:00
|
|
|
uses: lukka/run-vcpkg@v11
|
2020-05-03 21:15:48 +03:00
|
|
|
with:
|
2022-07-23 20:15:48 +03:00
|
|
|
vcpkgDirectory: ${{ runner.workspace }}/vcpkg
|
2023-04-08 07:34:03 +03:00
|
|
|
vcpkgGitCommitId: 5b1214315250939257ef5d62ecdcbca18cf4fb1c # For vcpkg-tool 2023-03-29.
|
2020-05-03 21:15:48 +03:00
|
|
|
|
|
|
|
- name: Install Qt
|
2022-10-02 22:04:33 +03:00
|
|
|
uses: jurplel/install-qt-action@v3
|
2020-05-03 21:15:48 +03:00
|
|
|
with:
|
2020-07-04 02:31:16 +03:00
|
|
|
arch: win64_msvc2019_64
|
2022-10-02 22:04:33 +03:00
|
|
|
modules: ${{ matrix.config.qt_modules }}
|
2020-05-10 17:31:39 +03:00
|
|
|
version: ${{ matrix.config.qt_version }}
|
2022-10-02 22:04:33 +03:00
|
|
|
cache: true
|
|
|
|
extra: --external 7z
|
2020-05-03 21:15:48 +03:00
|
|
|
|
|
|
|
- name: Configure & Build
|
2022-07-23 20:15:48 +03:00
|
|
|
uses: lukka/run-cmake@v10
|
2020-05-03 21:15:48 +03:00
|
|
|
with:
|
2022-07-23 20:15:48 +03:00
|
|
|
configurePreset: ${{ matrix.config.configurePreset }}
|
|
|
|
buildPreset: ${{ matrix.config.buildPreset }}
|
2020-05-03 21:15:48 +03:00
|
|
|
|
2023-04-09 09:25:54 +03:00
|
|
|
- name: Retrieve Application Version
|
|
|
|
run: |
|
|
|
|
$zeal_version = Get-Content build/${{ matrix.config.configurePreset }}/zeal_version
|
|
|
|
Write-Output "Zeal Version: $zeal_version"
|
|
|
|
"ZEAL_VERSION=$zeal_version" >> $env:GITHUB_ENV
|
|
|
|
|
2023-09-08 07:00:46 +03:00
|
|
|
- name: Package
|
2023-04-29 07:42:38 +03:00
|
|
|
if: matrix.config.publishArtifacts
|
2023-09-08 07:00:46 +03:00
|
|
|
run: cmake --build build --preset ${{ matrix.config.buildPreset }} --target package
|
2023-09-11 08:50:17 +03:00
|
|
|
env:
|
|
|
|
CODESIGN_CERTIFICATE: ${{ secrets.CODESIGN_CERTIFICATE }}
|
|
|
|
CODESIGN_PASSWORD: ${{ secrets.CODESIGN_PASSWORD }}
|
2023-04-09 09:25:54 +03:00
|
|
|
|
2023-09-11 06:15:22 +03:00
|
|
|
- name: Upload ZIP Artifacts
|
2023-04-29 07:24:55 +03:00
|
|
|
if: matrix.config.publishArtifacts
|
2023-04-09 09:25:54 +03:00
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
2023-09-11 06:15:22 +03:00
|
|
|
name: zeal-${{ env.ZEAL_VERSION }}${{ matrix.config.configurePreset == 'ninja-multi-vcpkg-portable' && '-portable' || '' }}-windows-x64.zip
|
|
|
|
path: |
|
|
|
|
build/${{ matrix.config.configurePreset }}/zeal-*.zip
|
|
|
|
build/${{ matrix.config.configurePreset }}/zeal-*.zip.sha256
|
|
|
|
|
|
|
|
- name: Upload MSI Artifacts
|
|
|
|
if: matrix.config.publishArtifacts && matrix.config.configurePreset == 'ninja-multi-vcpkg'
|
|
|
|
uses: actions/upload-artifact@v3
|
|
|
|
with:
|
|
|
|
name: zeal-${{ env.ZEAL_VERSION }}-windows-x64.msi
|
2023-04-09 09:25:54 +03:00
|
|
|
path: |
|
2023-09-11 06:15:22 +03:00
|
|
|
build/${{ matrix.config.configurePreset }}/zeal-*.msi
|
|
|
|
build/${{ matrix.config.configurePreset }}/zeal-*.msi.sha256
|
2023-04-09 09:25:54 +03:00
|
|
|
|
2020-09-06 06:22:51 +03:00
|
|
|
build-appimage:
|
2020-04-21 08:53:37 +03:00
|
|
|
name: AppImage
|
2020-09-06 06:22:51 +03:00
|
|
|
runs-on: ubuntu-20.04
|
2020-04-21 08:53:37 +03:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout
|
2023-09-05 05:16:25 +03:00
|
|
|
uses: actions/checkout@v4
|
2020-09-21 09:06:30 +03:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
2020-04-21 08:53:37 +03:00
|
|
|
|
|
|
|
- name: Build AppImage
|
|
|
|
uses: ./.github/workflows/appimage/
|
|
|
|
with:
|
2023-09-08 07:54:02 +03:00
|
|
|
recipe: pkg/appimage/appimage-amd64.yaml
|
2020-04-21 08:53:37 +03:00
|
|
|
apt_dependencies: >-
|
|
|
|
build-essential
|
|
|
|
cmake extra-cmake-modules
|
|
|
|
libappindicator-dev
|
|
|
|
libarchive-dev
|
|
|
|
libqt5x11extras5-dev
|
|
|
|
libsqlite3-dev
|
|
|
|
libxcb-keysyms1-dev
|
|
|
|
ninja-build
|
|
|
|
qtbase5-dev
|
2020-04-27 02:17:12 +03:00
|
|
|
qtwebengine5-dev
|
2020-04-21 08:53:37 +03:00
|
|
|
|
|
|
|
- name: Upload AppImage
|
2022-07-23 21:47:38 +03:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-04-21 08:53:37 +03:00
|
|
|
with:
|
|
|
|
name: zeal-dev-x86_64.AppImage # TODO: Provide real version.
|
|
|
|
path: zeal-*.AppImage
|
|
|
|
|
|
|
|
# TODO: Enable for releases.
|
|
|
|
- name: Upload AppImage.zsync
|
|
|
|
if: github.event_name == 'create' && github.event.ref_type == 'tag' && startsWith(github.ref, 'v')
|
2023-04-29 07:24:55 +03:00
|
|
|
uses: actions/upload-artifact@v3
|
2020-04-21 08:53:37 +03:00
|
|
|
with:
|
|
|
|
name: zeal-dev-x86_64.AppImage.zsync
|
|
|
|
path: zeal-*.AppImage.zsync
|