feat(appimage): use AnyLinux AppImages to support musl-libc and non-FHS systems
Signed-off-by: Boris Yumankulov <boria138@altlinux.org>
This commit is contained in:
75
build-aux/AppImage/get-dependencies.sh
Executable file
75
build-aux/AppImage/get-dependencies.sh
Executable file
@@ -0,0 +1,75 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -eu
|
||||
|
||||
# Determine if git mode is enabled based on the first argument
|
||||
if [ "${1:-}" = "--git" ] || [ "${1:-}" = "-g" ]; then
|
||||
GIT_MODE=true
|
||||
else
|
||||
GIT_MODE=false
|
||||
fi
|
||||
|
||||
ARCH="$(uname -m)"
|
||||
PACKAGE_BUILDER="https://raw.githubusercontent.com/pkgforge-dev/Anylinux-AppImages/refs/heads/main/useful-tools/make-aur-package.sh"
|
||||
EXTRA_PACKAGES="https://raw.githubusercontent.com/pkgforge-dev/Anylinux-AppImages/refs/heads/main/useful-tools/get-debloated-pkgs.sh"
|
||||
|
||||
if [ "$GIT_MODE" = true ]; then
|
||||
echo "Using git version of PortProtonQt..."
|
||||
PPQT_PKGBUILD="https://git.linux-gaming.ru/Boria138/PortProtonQt/raw/branch/main/build-aux/PKGBUILD-git"
|
||||
else
|
||||
echo "Using stable version of PortProtonQt..."
|
||||
PPQT_PKGBUILD="https://git.linux-gaming.ru/Boria138/PortProtonQt/raw/branch/main/build-aux/PKGBUILD"
|
||||
fi
|
||||
|
||||
|
||||
echo "Installing dependencies..."
|
||||
echo "---------------------------------------------------------------"
|
||||
pacman-key --init
|
||||
pacman -Syy --needed --noconfirm archlinux-keyring
|
||||
pacman -Syu --needed --noconfirm \
|
||||
cabextract \
|
||||
curl \
|
||||
perl-image-exiftool \
|
||||
pyside6 \
|
||||
python-babel \
|
||||
python-beautifulsoup4 \
|
||||
python-evdev \
|
||||
python-numpy \
|
||||
python-orjson \
|
||||
python-pillow \
|
||||
python-psutil \
|
||||
python-pyudev \
|
||||
python-rapidfuzz \
|
||||
python-requests \
|
||||
python-tqdm \
|
||||
python-websocket-client \
|
||||
unrar \
|
||||
unzip \
|
||||
xdg-utils
|
||||
|
||||
echo "Installing debloated packages..."
|
||||
echo "---------------------------------------------------------------"
|
||||
wget --retry-connrefused --tries=30 "$EXTRA_PACKAGES" -O ./get-debloated-pkgs.sh
|
||||
chmod +x ./get-debloated-pkgs.sh
|
||||
./get-debloated-pkgs.sh --add-common --prefer-nano
|
||||
|
||||
echo "Installing AUR packages..."
|
||||
echo "---------------------------------------------------------------"
|
||||
wget --retry-connrefused --tries=30 "$PACKAGE_BUILDER" -O ./make-aur-package.sh
|
||||
chmod +x ./make-aur-package.sh
|
||||
|
||||
./make-aur-package.sh --chaotic-aur icoextract
|
||||
./make-aur-package.sh --chaotic-aur python-vdf
|
||||
|
||||
echo "Building PortProtonQt from PKGBUILD..."
|
||||
echo "---------------------------------------------------------------"
|
||||
wget --retry-connrefused --tries=30 "$PPQT_PKGBUILD" -O ./PKGBUILD
|
||||
makepkg -si --noconfirm
|
||||
|
||||
if [ "$GIT_MODE" = true ]; then
|
||||
# For git version, we use portprotonqt-git
|
||||
pacman -Q portprotonqt-git | awk '{print $2; exit}' > ~/version
|
||||
else
|
||||
# For stable version, we use portprotonqt
|
||||
pacman -Q portprotonqt | awk '{print $2; exit}' > ~/version
|
||||
fi
|
||||
26
build-aux/AppImage/portprotonqt-appimage.sh
Executable file
26
build-aux/AppImage/portprotonqt-appimage.sh
Executable file
@@ -0,0 +1,26 @@
|
||||
#!/bin/sh
|
||||
|
||||
set -eu
|
||||
|
||||
SHARUN="https://raw.githubusercontent.com/pkgforge-dev/Anylinux-AppImages/refs/heads/main/useful-tools/quick-sharun.sh"
|
||||
ARCH="$(uname -m)"
|
||||
VERSION="$(cat ~/version)"
|
||||
export ARCH VERSION
|
||||
export OUTPATH=./dist
|
||||
export DESKTOP=/usr/share/applications/ru.linux_gaming.PortProtonQt.desktop
|
||||
export ICON=/usr/share/icons/hicolor/scalable/apps/ru.linux_gaming.PortProtonQt.svg
|
||||
export OUTNAME=portprotonqt-"$VERSION"-anylinux-"$ARCH".AppImage
|
||||
export DEPLOY_OPENGL=1
|
||||
export DEPLOY_PIPEWIRE=1
|
||||
export DEPLOY_SYS_PYTHON=1
|
||||
export DEPLOY_VULKAN=1
|
||||
export ANYLINUX_LIB=1
|
||||
export OPTIMIZE_LAUNCH=1
|
||||
|
||||
# DEPLOY ALL LIBS
|
||||
wget --retry-connrefused --tries=30 "$SHARUN" -O ./quick-sharun
|
||||
chmod +x ./quick-sharun
|
||||
./quick-sharun /usr/bin/portprotonqt /usr/lib/libudev.so*
|
||||
|
||||
# Turn AppDir into AppImage
|
||||
./quick-sharun --make-appimage
|
||||
Reference in New Issue
Block a user