Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Github Actions CI builds #768

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 71 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
name: CI Build

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

jobs:
build:
runs-on: ${{ matrix.os }}

defaults:
run:
shell: bash

strategy:
matrix:
os: [ubuntu-latest, macos-latest]
build-type:
- ''
- '-DGAMMARAY_CLIENT_ONLY_BUILD=1'
# - '-DGAMMARAY_PROBE_ONLY_BUILD=1 -DGAMMARAY_BUILD_UI=0'
qt-version: ['5.15.*', '6.4.*']

steps:
- uses: actions/checkout@v3
- name: Configure Python (Linux)
if: ${{ runner.os }} == 'linux'
run: |
sudo python3 -m pip install wheel
sudo python3 -m pip install --upgrade setuptools
sudo python3 -m pip install 'py7zr==0.19.*'
- name: Install Qt
uses: jurplel/install-qt-action@v3
with:
version: ${{ matrix.qt-version }}
cache: true
setup-python: false
- name: Configure
run: |
MATRIX_QT_VERSION=${{ matrix.qt-version }}
QT_MAJOR_VERSION=${MATRIX_QT_VERSION:0:1}
if [ $QT_MAJOR_VERSION == "6" ]; then
EXTRA_CMAKE_FLAGS="-DGAMMARAY_QT6_BUILD=1 -DQT_MAJOR_VERSION=${QT_MAJOR_VERSION}";
fi
cmake -B _build -S . \
${{ matrix.build-type }} ${EXTRA_CMAKE_FLAGS}
- name: Build
run: |
cmake --build _build
- name: Install
run: |
cmake --install _build --prefix ./install
- name: Deploy (Linux) - Disabled due to GammaRay GLIBC_2.28 requirement
if: false
run: |
sudo apt install libfuse2
wget -c "https://github.com/probonopd/linuxdeployqt/releases/download/continuous/linuxdeployqt-continuous-x86_64.AppImage"
chmod a+x linuxdeployqt*.AppImage
unset QTDIR; unset QT_PLUGIN_PATH ; unset LD_LIBRARY_PATH
./linuxdeployqt*.AppImage ./install/usr/share/applications/GammaRay.desktop -bundle-non-qt-libs
# Workaround for https://github.com/probonopd/linuxdeployqt/issues/83
./linuxdeployqt*.AppImage --appimage-extract
./squashfs-root/usr/bin/patchelf --set-rpath '$ORIGIN/../..' ./appdir/usr/lib/gammaray/libexec/gammaray-launcher
./squashfs-root/usr/bin/patchelf --set-rpath '$ORIGIN/../..' ./appdir/usr/lib/gammaray/libexec/gammaray-client
# Apparently the qt_prfxpath in libQt5Core.so
# is not relative to libQt5Core.so but to the binary that is being executed, is this clever?
( cd ./appdir/usr/lib/gammaray/ ; ln -s ../../plugins/ . )
./linuxdeployqt*.AppImage ./appdir/usr/share/applications/GammaRay.desktop -appimage
# curl --upload-file ./GammaRay-*.AppImage https://transfer.sh/GammaRay-git.$(git rev-parse --short HEAD)-x86_64.AppImage
2 changes: 1 addition & 1 deletion .reuse/dep5
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ Copyright: 2010-2023 Klarälvdalens Datakonsult AB, a KDAB Group company <info@k
License: GPL-2.0-or-later

#misc config files
Files: 3rdparty/*/qt_attribution.json .clang-format .clang-tidy .clangd .clazy .cmake-format.py .codespellrc .emacs-dirvars .git-blame-ignore-revs .gitattributes .gitignore .kateconfig .krazy .mdlrc .mdlrc.rb .pep8 .pre-commit-config.yaml .pylintrc .qmake.conf .tag .travis.yml appveyor.ini appveyor.yml distro/* format.config.uncrustify.4_spaces *.qdocconf format_sources docs/collection/gammaray.qhcp.cmake examples/yocto/gammaray_git*.bb probe/gammaray_probe-android-dependencies.xml docs/api/Doxyfile.cmake
Files: 3rdparty/*/qt_attribution.json .clang-format .clang-tidy .clangd .clazy .cmake-format.py .codespellrc .emacs-dirvars .git-blame-ignore-revs .gitattributes .gitignore .kateconfig .krazy .mdlrc .mdlrc.rb .pep8 .pre-commit-config.yaml .pylintrc .qmake.conf .tag .travis.yml appveyor.ini appveyor.yml distro/* format.config.uncrustify.4_spaces *.qdocconf format_sources docs/collection/gammaray.qhcp.cmake examples/yocto/gammaray_git*.bb probe/gammaray_probe-android-dependencies.xml docs/api/Doxyfile.cmake .github/workflows/*.yml
Copyright: 2010-2023 Klarälvdalens Datakonsult AB, a KDAB Group company <[email protected]>
License: BSD-3-Clause

Expand Down