Testing probonopd/go-appimage#301 #2 #80
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Linux build | |
on: | |
push: | |
branches: | |
- master | |
- next | |
- 'next*' | |
tags: | |
- 'v*' | |
jobs: | |
qtbuild: | |
name: Build with Qt | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Install Qt | |
uses: jurplel/install-qt-action@v4 | |
with: | |
version: '6.7.2' | |
modules: 'qtcharts qtmultimedia qt5compat qtshadertools' | |
- name: Checkout | |
uses: actions/checkout@v4 | |
- run: git fetch --prune --unshallow --tags | |
- name: Set environment variables | |
run: | | |
echo "DATE=`date +%Y%m%d`" >> $GITHUB_ENV | |
echo "GIT_HASH=`git rev-parse --short HEAD`" >> $GITHUB_ENV | |
#echo "QTDIR=$QT_ROOT_DIR" >> $GITHUB_ENV | |
cat $GITHUB_ENV | |
- name: Display environment variables | |
run: env | sort | |
- name: Install build dependencies | |
run: | | |
set -x | |
sudo apt-get -y install build-essential libfaad-dev libmpg123-dev libfftw3-dev librtlsdr-dev libusb-1.0-0-dev mesa-common-dev libglu1-mesa-dev libpulse-dev libsoapysdr-dev libairspy-dev libmp3lame-dev libflac++-dev | |
- name: Build | |
id: build | |
run: | | |
mkdir build | |
cd build | |
qmake PREFIX=/usr .. | |
make -j4 | |
cd .. | |
echo $PWD | |
- name: Prepare welle-io AppImage | |
id: prepare_app_image | |
run: | | |
find build/ | |
mkdir -p ./appdir/usr/share/applications | |
cp welle-io.desktop ./appdir/usr/share/applications | |
mkdir -p ./appdir/usr/bin | |
cp build/src/welle-gui/welle-io ./appdir/usr/bin | |
mkdir -p ./appdir/usr/lib | |
mkdir -p ./appdir/usr/share/icons/hicolor/256x256/apps/ | |
cp src/welle-gui/icons/icon.png ./appdir/usr/share/icons/hicolor/256x256/apps/welle-io.png | |
find appdir/ | |
- name: Create AppImage | |
id: create_appimage | |
run: | | |
# Get appimagetool | |
# wget -c https://github.com/$(wget -q https://github.com/probonopd/go-appimage/releases/expanded_assets/continuous -O - | grep "appimagetool-.*-x86_64.AppImage" | head -n 1 | cut -d '"' -f 2) | |
wget https://welle-io-nightlies.albrechtloh.de/appimagetool-843-x86_64.AppImage # just for testing | |
chmod +x appimagetool-*.AppImage | |
# Create AppImage | |
./appimagetool-*.AppImage -s deploy ./appdir/usr/share/applications/*.desktop # Bundle EVERYTHING | |
find appdir/ | |
grep -r 'Could not initialize GLX' ./appdir | |
ldd Qt/6.7.2/gcc_64/plugins/xcbglintegration/libqxcb-glx-integration.so | |
VERSION=1.0 ./appimagetool-*.AppImage ./appdir # turn AppDir into AppImage | |
# Preapre publish | |
mkdir publish | |
mv welle.io-1.0-x86_64.AppImage publish/"$DATE"_"$GIT_HASH"_Linux_welle-io-x86_64.AppImage | |
- name: Archive artifacts (welle.io AppImage) | |
if: always() && steps.create_appimage.outcome == 'success' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: welle.io AppImage | |
path: publish/*welle-io-x86_64.AppImage | |
if-no-files-found: error | |
- name: Upload to nightly server | |
if: always() && steps.create_appimage.outcome == 'success' | |
uses: dennisameling/ftp-upload-action@v1 | |
with: | |
server: a2f24.netcup.net # welle-io-nightlies.albrechtloh.de is redirected to here | |
secure: true | |
username: ${{ secrets.SFTP_USER }} | |
password: ${{ secrets.SFTP_PASSWORD }} | |
local_dir: publish/ |