mirror of
https://github.com/edisionnano/QDiskInfo.git
synced 2026-04-12 21:11:28 +03:00
Merge pull request #41 from Samueru-sama/main
add `Breeze` theme and add `aarch64` builds
This commit is contained in:
91
.github/workflows/build.yaml
vendored
91
.github/workflows/build.yaml
vendored
@@ -3,53 +3,70 @@ name: Build
|
|||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
branches:
|
branches:
|
||||||
- main
|
- main
|
||||||
paths-ignore:
|
paths-ignore:
|
||||||
- '**.md'
|
- "**.md"
|
||||||
pull_request:
|
pull_request:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
runs-on: ubuntu-24.04
|
permissions:
|
||||||
|
actions: read
|
||||||
|
security-events: write
|
||||||
|
contents: write
|
||||||
|
runs-on: ${{ matrix.runs-on }}
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- arch: aarch64
|
||||||
|
platform: linux/arm64
|
||||||
|
runs-on: ubuntu-24.04-arm
|
||||||
|
- arch: x86_64
|
||||||
|
platform: linux/amd64
|
||||||
|
runs-on: ubuntu-24.04
|
||||||
|
container:
|
||||||
|
image: ghcr.io/pkgforge-dev/archlinux:latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v4
|
- uses: actions/checkout@v4
|
||||||
|
|
||||||
- name: Install dependencies
|
- name: Install dependencies
|
||||||
run: |
|
run: |
|
||||||
sudo apt update
|
pacman -Syu --noconfirm \
|
||||||
sudo apt install -y \
|
base-devel \
|
||||||
libgl1-mesa-dev \
|
breeze \
|
||||||
libvulkan-dev \
|
clang \
|
||||||
libxkbcommon-dev \
|
cmake \
|
||||||
patchelf \
|
libxkbcommon \
|
||||||
qmake6 \
|
mesa \
|
||||||
qt6-base-dev \
|
patchelf \
|
||||||
qt6ct \
|
qt6-base \
|
||||||
qt6-svg-dev \
|
qt6ct \
|
||||||
qt6-tools-dev \
|
qt6-svg \
|
||||||
smartmontools \
|
qt6-tools \
|
||||||
wget
|
smartmontools \
|
||||||
|
vulkan-devel \
|
||||||
|
wget
|
||||||
|
|
||||||
- name: Build
|
- name: Build
|
||||||
run: |
|
run: |
|
||||||
cmake -Bbuild -DCMAKE_BUILD_TYPE:STRING=MinSizeRel -DQT_VERSION_MAJOR=6 -DENABLE_TRANSLATIONS=ON
|
cmake -Bbuild -DCMAKE_BUILD_TYPE:STRING=MinSizeRel -DQT_VERSION_MAJOR=6 -DENABLE_TRANSLATIONS=ON
|
||||||
cmake --build build
|
cmake --build build
|
||||||
|
|
||||||
- name: Package AppImage
|
- name: Package AppImage
|
||||||
run: |
|
run: |
|
||||||
chmod +x ./qdiskinfo-appimage.sh
|
chmod +x ./qdiskinfo-appimage.sh
|
||||||
./qdiskinfo-appimage.sh
|
./qdiskinfo-appimage.sh
|
||||||
|
|
||||||
- name: Upload AppImage
|
- name: Upload AppImage
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: QDiskInfo-anylinux-AppImage
|
name: QDiskInfo-${{ matrix.arch }}-AppImage
|
||||||
path: ./QDiskInfo*.AppImage
|
path: ./QDiskInfo*.AppImage
|
||||||
|
|
||||||
- name: Upload Binaries
|
- name: Upload Binaries
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v4
|
||||||
with:
|
with:
|
||||||
name: QDiskInfo-Qt6-bin
|
name: QDiskInfo-Qt6-${{ matrix.arch }}-bin
|
||||||
path: ./build/QDiskInfo
|
path: ./build/QDiskInfo
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ set -eu
|
|||||||
|
|
||||||
export ARCH="$(uname -m)"
|
export ARCH="$(uname -m)"
|
||||||
export APPIMAGE_EXTRACT_AND_RUN=1
|
export APPIMAGE_EXTRACT_AND_RUN=1
|
||||||
|
export QT_STYLE_OVERRIDE=Breeze # Make sure the breeze theme is dlopened
|
||||||
|
|
||||||
APP=QDiskInfo
|
APP=QDiskInfo
|
||||||
APPIMAGETOOL="https://github.com/pkgforge-dev/appimagetool-uruntime/releases/download/continuous/appimagetool-$ARCH.AppImage"
|
APPIMAGETOOL="https://github.com/pkgforge-dev/appimagetool-uruntime/releases/download/continuous/appimagetool-$ARCH.AppImage"
|
||||||
@@ -11,6 +12,17 @@ UPINFO="gh-releases-zsync|$(echo "$GITHUB_REPOSITORY" | tr '/' '|')|latest|*-$AR
|
|||||||
LIB4BN="https://raw.githubusercontent.com/VHSgunzo/sharun/refs/heads/main/lib4bin"
|
LIB4BN="https://raw.githubusercontent.com/VHSgunzo/sharun/refs/heads/main/lib4bin"
|
||||||
VERSION="$(echo "$GITHUB_SHA" | cut -c 1-9)-anylinux"
|
VERSION="$(echo "$GITHUB_SHA" | cut -c 1-9)-anylinux"
|
||||||
|
|
||||||
|
# Get iculess qt6-base, removes a 30 MiB lib from the appimage
|
||||||
|
if [ "$ARCH" = 'x86_64' ]; then
|
||||||
|
PKG_TYPE='x86_64.pkg.tar.zst'
|
||||||
|
else
|
||||||
|
PKG_TYPE='aarch64.pkg.tar.xz'
|
||||||
|
fi
|
||||||
|
QT6_URL="https://github.com/pkgforge-dev/llvm-libs-debloated/releases/download/continuous/qt6-base-iculess-$PKG_TYPE"
|
||||||
|
wget --retry-connrefused --tries=30 "$QT6_URL" -O ./qt6-base-iculess.pkg.tar.zst
|
||||||
|
pacman -U --noconfirm ./qt6-base-iculess.pkg.tar.zst
|
||||||
|
rm -f ./qt6-base-iculess.pkg.tar.zst
|
||||||
|
|
||||||
# Prepare AppDir
|
# Prepare AppDir
|
||||||
mkdir -p ./AppDir/shared/bin
|
mkdir -p ./AppDir/shared/bin
|
||||||
cp -v ./dist/QDiskInfo.desktop ./AppDir
|
cp -v ./dist/QDiskInfo.desktop ./AppDir
|
||||||
@@ -24,21 +36,22 @@ wget "$LIB4BN" -O ./lib4bin
|
|||||||
chmod +x ./lib4bin
|
chmod +x ./lib4bin
|
||||||
./lib4bin -p -v -s -k \
|
./lib4bin -p -v -s -k \
|
||||||
./shared/bin/QDiskInfo \
|
./shared/bin/QDiskInfo \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/iconengines/* \
|
/usr/lib/qt6/plugins/iconengines/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/imageformats/* \
|
/usr/lib/qt6/plugins/imageformats/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/platforms/* \
|
/usr/lib/qt6/plugins/platforms/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/platformthemes/* \
|
/usr/lib/qt6/plugins/platformthemes/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/styles/* \
|
/usr/lib/qt6/plugins/styles/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/xcbglintegrations/* \
|
/usr/lib/qt6/plugins/xcbglintegrations/* \
|
||||||
/usr/lib/"$ARCH"-linux-gnu/qt6/plugins/wayland-*/*
|
/usr/lib/qt6/plugins/wayland-*/*
|
||||||
|
|
||||||
# also use lib4bin to make a portable smartctl with wrappe
|
# also use lib4bin to make a portable smartctl with wrappe
|
||||||
./lib4bin --with-wrappe "$(command -v smartctl)"
|
./lib4bin -s --with-wrappe "$(command -v smartctl)"
|
||||||
|
|
||||||
# prepare sharun
|
# prepare sharun
|
||||||
echo '#!/bin/sh
|
echo '#!/bin/sh
|
||||||
CURRENTDIR="$(dirname "$(readlink -f "$0")")"
|
CURRENTDIR="$(dirname "$(readlink -f "$0")")"
|
||||||
CACHEDIR="${XDG_CACHE_HOME:-$HOME/.cache}"
|
CACHEDIR="${XDG_CACHE_HOME:-$HOME/.cache}"
|
||||||
|
export QT_STYLE_OVERRIDE="${QT_STYLE_OVERRIDE:-Breeze}"
|
||||||
[ -f "$APPIMAGE".stylesheet ] && APPIMAGE_QT_THEME="$APPIMAGE.stylesheet"
|
[ -f "$APPIMAGE".stylesheet ] && APPIMAGE_QT_THEME="$APPIMAGE.stylesheet"
|
||||||
[ -f "$APPIMAGE_QT_THEME" ] && set -- "$@" "-stylesheet" "$APPIMAGE_QT_THEME"
|
[ -f "$APPIMAGE_QT_THEME" ] && set -- "$@" "-stylesheet" "$APPIMAGE_QT_THEME"
|
||||||
|
|
||||||
@@ -59,8 +72,5 @@ cd ..
|
|||||||
wget "$APPIMAGETOOL" -O ./appimagetool
|
wget "$APPIMAGETOOL" -O ./appimagetool
|
||||||
chmod +x ./appimagetool
|
chmod +x ./appimagetool
|
||||||
|
|
||||||
./appimagetool --comp zstd \
|
./appimagetool --no-appstream -u "$UPINFO" \
|
||||||
--mksquashfs-opt -Xcompression-level \
|
|
||||||
--mksquashfs-opt 22 \
|
|
||||||
--no-appstream -u "$UPINFO" \
|
|
||||||
"$PWD"/AppDir "$PWD"/"$APP"-"$VERSION"-"$ARCH".AppImage
|
"$PWD"/AppDir "$PWD"/"$APP"-"$VERSION"-"$ARCH".AppImage
|
||||||
|
|||||||
Reference in New Issue
Block a user