From d6f63656f1acd85891036cecd106fea1975576c8 Mon Sep 17 00:00:00 2001 From: Felitendo Date: Mon, 14 Sep 2026 23:38:11 +0200 Subject: [PATCH] moondeckbuddy, moondeckbuddy-bin: new packages --- README.md | 2 ++ moondeckbuddy-bin/.SRCINFO | 32 ++++++++++++++++++ moondeckbuddy-bin/PKGBUILD | 68 ++++++++++++++++++++++++++++++++++++++ moondeckbuddy-bin/pkg.sh | 35 ++++++++++++++++++++ moondeckbuddy/.SRCINFO | 27 +++++++++++++++ moondeckbuddy/PKGBUILD | 55 ++++++++++++++++++++++++++++++ moondeckbuddy/pkg.sh | 54 ++++++++++++++++++++++++++++++ 7 files changed, 273 insertions(+) create mode 100644 moondeckbuddy-bin/.SRCINFO create mode 100644 moondeckbuddy-bin/PKGBUILD create mode 100644 moondeckbuddy-bin/pkg.sh create mode 100644 moondeckbuddy/.SRCINFO create mode 100644 moondeckbuddy/PKGBUILD create mode 100644 moondeckbuddy/pkg.sh diff --git a/README.md b/README.md index 59f1f7c..f782700 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,8 @@ source in the `PKGBUILD` (and drop the `-bin` suffix), or don't package it. | `lunar-client-bin` | [lunarclient.com](https://lunarclient.com) — Minecraft PvP modpack launcher | AppImage | [lunar-client-bin](https://aur.archlinux.org/packages/lunar-client-bin) | | `middleclick-autoscroll` | [Felitendo/middleclick-autoscroll](https://github.com/Felitendo/middleclick-autoscroll) — enables middle-click autoscroll in every application that supports it | *built from source* | [middleclick-autoscroll](https://aur.archlinux.org/packages/middleclick-autoscroll) | | `modrinth-app-bin` | [modrinth/code](https://github.com/modrinth/code) — Minecraft mod manager/launcher | `.deb` | [modrinth-app-bin](https://aur.archlinux.org/packages/modrinth-app-bin) | +| `moondeckbuddy` | [FrogTheFrog/moondeck-buddy](https://github.com/FrogTheFrog/moondeck-buddy) — host companion of the MoonDeck Steam Deck plugin (C++/Qt6) | *built from source* | [moondeckbuddy](https://aur.archlinux.org/packages/moondeckbuddy) | +| `moondeckbuddy-bin` | [FrogTheFrog/moondeck-buddy](https://github.com/FrogTheFrog/moondeck-buddy) — prebuilt release of `moondeckbuddy` | AppImage | *not published yet* | | `nextcloud-native` | [Obiente/nc-native](https://github.com/Obiente/nc-native) — adaptive native Nextcloud client for files, media and installed server apps (Compose Multiplatform, unofficial) | *built from source* | [nextcloud-native](https://aur.archlinux.org/packages/nextcloud-native) | | `nextcloud-native-bin` | [Obiente/nc-native](https://github.com/Obiente/nc-native) — prebuilt release of `nextcloud-native` | `.deb` | [nextcloud-native-bin](https://aur.archlinux.org/packages/nextcloud-native-bin) | | `nextcloud-native-git` | [Obiente/nc-native](https://github.com/Obiente/nc-native) — `main` branch of `nextcloud-native` | *built from source* | [nextcloud-native-git](https://aur.archlinux.org/packages/nextcloud-native-git) | diff --git a/moondeckbuddy-bin/.SRCINFO b/moondeckbuddy-bin/.SRCINFO new file mode 100644 index 0000000..33ab832 --- /dev/null +++ b/moondeckbuddy-bin/.SRCINFO @@ -0,0 +1,32 @@ +pkgbase = moondeckbuddy-bin + pkgdesc = Host companion that lets the MoonDeck Steam Deck plugin control Steam and the PC (upstream AppImage) + pkgver = 1.10.0 + pkgrel = 1 + url = https://github.com/FrogTheFrog/moondeck-buddy + arch = x86_64 + license = LGPL-3.0-only + depends = bash + depends = e2fsprogs + depends = fontconfig + depends = freetype2 + depends = glibc + depends = hicolor-icon-theme + depends = libgcc + depends = libglvnd + depends = libgpg-error + depends = libstdc++ + depends = libx11 + depends = libxcb + depends = zlib + provides = moondeckbuddy + conflicts = moondeckbuddy + conflicts = moondeckbuddy-appimage + noextract = moondeckbuddy-bin-1.10.0.AppImage + options = !strip + options = !debug + source = moondeckbuddy-bin-1.10.0.AppImage::https://github.com/FrogTheFrog/moondeck-buddy/releases/download/v1.10.0/MoonDeckBuddy-1.10.0-x86_64.AppImage + source = LICENSE-1.10.0::https://raw.githubusercontent.com/FrogTheFrog/moondeck-buddy/v1.10.0/LICENSE + sha256sums = 51960ec27f897818e10f6e06a3c8994eebfd05c58c9c51ed89cad5b53caa5a46 + sha256sums = a5681bf9b05db14d86776930017c647ad9e6e56ff6bbcfdf21e5848288dfaf1b + +pkgname = moondeckbuddy-bin diff --git a/moondeckbuddy-bin/PKGBUILD b/moondeckbuddy-bin/PKGBUILD new file mode 100644 index 0000000..cff3e6c --- /dev/null +++ b/moondeckbuddy-bin/PKGBUILD @@ -0,0 +1,68 @@ +# Maintainer: Felitendo +# This PKGBUILD is updated automatically: +# https://github.com/Felitendo/PKGBUILDS + +pkgname=moondeckbuddy-bin +pkgver=1.10.0 +pkgrel=1 +pkgdesc="Host companion that lets the MoonDeck Steam Deck plugin control Steam and the PC (upstream AppImage)" +arch=('x86_64') +url="https://github.com/FrogTheFrog/moondeck-buddy" +license=('LGPL-3.0-only') +# the AppImage bundles Qt6, OpenSSL, glib, libproc2 and the xcb stack; these +# are what is left over (bash runs upstream's AppRun) +depends=('bash' 'e2fsprogs' 'fontconfig' 'freetype2' 'glibc' + 'hicolor-icon-theme' 'libgcc' 'libglvnd' 'libgpg-error' 'libstdc++' + 'libx11' 'libxcb' 'zlib') +provides=('moondeckbuddy') +conflicts=('moondeckbuddy' 'moondeckbuddy-appimage') +options=('!strip' '!debug') +source=("${pkgname}-${pkgver}.AppImage::https://github.com/FrogTheFrog/moondeck-buddy/releases/download/v${pkgver}/MoonDeckBuddy-${pkgver}-x86_64.AppImage" + "LICENSE-${pkgver}::https://raw.githubusercontent.com/FrogTheFrog/moondeck-buddy/v${pkgver}/LICENSE") +noextract=("${pkgname}-${pkgver}.AppImage") +sha256sums=('51960ec27f897818e10f6e06a3c8994eebfd05c58c9c51ed89cad5b53caa5a46' 'a5681bf9b05db14d86776930017c647ad9e6e56ff6bbcfdf21e5848288dfaf1b') + +prepare() { + chmod +x "$srcdir/${pkgname}-${pkgver}.AppImage" + "$srcdir/${pkgname}-${pkgver}.AppImage" --appimage-extract > /dev/null +} + +package() { + local _root="$srcdir/squashfs-root" + + # upstream's AppImage payload, installed unchanged apart from the top-level + # icon/desktop symlinks only the AppImage runtime uses + install -d "$pkgdir/opt/$pkgname" + cp -a "$_root/." "$pkgdir/opt/$pkgname/" + rm -f "$pkgdir/opt/$pkgname/"{.DirIcon,MoonDeckBuddy.desktop,moondeckbuddy.png} + # the bundled libraries' copyright files are world-writable in the image, + # and linuxdeploy leaves a few empty directories behind + chmod -R go-w "$pkgdir/opt/$pkgname" + find "$pkgdir/opt/$pkgname" -type d -empty -delete + + # The AppRun forces the bundled xcb platform plugin (there is no Wayland one + # in the bundle), so the binaries go through it. Buddy writes its own path + # into the autostart entry and systemd user service it creates and takes it + # from $APPIMAGE when set - pointing that at the wrapper keeps autostart on + # the AppRun too, just as the AppRun does with the AppImage's own path. + install -d "$pkgdir/usr/bin" + local _bin + for _bin in MoonDeckBuddy MoonDeckStream; do + cat > "$pkgdir/usr/bin/$_bin" << EOF +#!/bin/sh +APPIMAGE=/usr/bin/$_bin exec /opt/$pkgname/AppRun --exec $_bin "\$@" +EOF + chmod 755 "$pkgdir/usr/bin/$_bin" + done + + install -Dm644 "$_root/usr/share/applications/MoonDeckBuddy.desktop" \ + "$pkgdir/usr/share/applications/MoonDeckBuddy.desktop" + local _size + for _size in 16 32 64 128 256; do + install -Dm644 "$_root/usr/share/icons/hicolor/${_size}x${_size}/apps/moondeckbuddy.png" \ + "$pkgdir/usr/share/icons/hicolor/${_size}x${_size}/apps/moondeckbuddy.png" + done + + install -Dm644 "$srcdir/LICENSE-${pkgver}" \ + "$pkgdir/usr/share/licenses/$pkgname/LICENSE" +} diff --git a/moondeckbuddy-bin/pkg.sh b/moondeckbuddy-bin/pkg.sh new file mode 100644 index 0000000..dbaa3cb --- /dev/null +++ b/moondeckbuddy-bin/pkg.sh @@ -0,0 +1,35 @@ +# moondeckbuddy-bin - MoonDeck Buddy (https://github.com/FrogTheFrog/moondeck-buddy), +# the host-side companion of the MoonDeck Steam Deck plugin (C++23 + Qt6). +# +# Upstream publishes a linuxdeploy AppImage per release, which the PKGBUILD +# unpacks into /opt - so there is no build step here, only pkgver and the +# checksums are refreshed on a new version. The license text is not part of +# the AppImage and comes from the matching source tag. +# +# Releases are created as drafts by upstream's CI and published by hand, so +# /releases/latest never points at a release whose assets are still missing. + +UPSTREAM_REPO="FrogTheFrog/moondeck-buddy" + +# The AUR already carries moondeckbuddy-appimage, which ships the same upstream +# AppImage, so publishing this as well would be a second copy of one package. +# Flip this to true to publish; until then the PKGBUILD is still kept current +# and test-built here. +AUR_PUBLISH=false + +latest_version() { + gh api "repos/$UPSTREAM_REPO/releases/latest" --jq '.tag_name' | sed 's/^v//' +} + +# refresh_checksums +refresh_checksums() { + local ver="$1" pkgbuild="$2" + local sha_img sha_lic + + sha_img="$(curl -sfL "https://github.com/$UPSTREAM_REPO/releases/download/v$ver/MoonDeckBuddy-$ver-x86_64.AppImage" \ + | sha256sum | cut -d' ' -f1)" + sha_lic="$(curl -sfL "https://raw.githubusercontent.com/$UPSTREAM_REPO/v$ver/LICENSE" \ + | sha256sum | cut -d' ' -f1)" + + sed -i "s|^sha256sums=.*|sha256sums=('$sha_img' '$sha_lic')|" "$pkgbuild" +} diff --git a/moondeckbuddy/.SRCINFO b/moondeckbuddy/.SRCINFO new file mode 100644 index 0000000..9c0369f --- /dev/null +++ b/moondeckbuddy/.SRCINFO @@ -0,0 +1,27 @@ +pkgbase = moondeckbuddy + pkgdesc = Host companion that lets the MoonDeck Steam Deck plugin control Steam and the PC + pkgver = 1.10.0 + pkgrel = 1 + url = https://github.com/FrogTheFrog/moondeck-buddy + arch = x86_64 + license = LGPL-3.0-only + license = MIT + makedepends = cmake + makedepends = ninja + depends = glibc + depends = hicolor-icon-theme + depends = libgcc + depends = libstdc++ + depends = procps-ng + depends = qt6-base + depends = qt6-httpserver + depends = qt6-websockets + conflicts = moondeckbuddy-appimage + source = moondeckbuddy-1.10.0.tar.gz::https://github.com/FrogTheFrog/moondeck-buddy/archive/refs/tags/v1.10.0.tar.gz + source = moondeck-keys-9d1cc7356181f6f6c0aa2a5e92ad7174f09fa539.tar.gz::https://github.com/FrogTheFrog/moondeck-keys/archive/9d1cc7356181f6f6c0aa2a5e92ad7174f09fa539.tar.gz + source = glaze-7.7.1.tar.gz::https://github.com/stephenberry/glaze/archive/refs/tags/v7.7.1.tar.gz + sha256sums = f68aff3e26c51618bd78e7656cfe3481fd0c4d2be377a26fc4e5db54e9541642 + sha256sums = 80438b7cec54f89e3b03ad4bf1bf46edd36a8438e5ebcdb5333ecacd45aba7cc + sha256sums = c51217ca374f2a7d556c501a849d3a43dfffff47ba7711b6f0c22020e71ff63d + +pkgname = moondeckbuddy diff --git a/moondeckbuddy/PKGBUILD b/moondeckbuddy/PKGBUILD new file mode 100644 index 0000000..ec9da13 --- /dev/null +++ b/moondeckbuddy/PKGBUILD @@ -0,0 +1,55 @@ +# Maintainer: Felitendo +# This PKGBUILD is updated automatically: +# https://github.com/Felitendo/PKGBUILDS + +pkgname=moondeckbuddy +pkgver=1.10.0 +pkgrel=1 +pkgdesc="Host companion that lets the MoonDeck Steam Deck plugin control Steam and the PC" +arch=('x86_64') +url="https://github.com/FrogTheFrog/moondeck-buddy" +# MIT: glaze, a header-only JSON library compiled into both binaries +license=('LGPL-3.0-only' 'MIT') +depends=('glibc' 'hicolor-icon-theme' 'libgcc' 'libstdc++' 'procps-ng' + 'qt6-base' 'qt6-httpserver' 'qt6-websockets') +makedepends=('cmake' 'ninja') +conflicts=('moondeckbuddy-appimage') +# The tag tarball carries neither the resources/ssl submodule (the self-signed +# certificate Buddy and MoonDeck share) nor glaze, which CMake would fetch at +# configure time. Both are pinned to what the tag references; see pkg.sh. +_keys_commit="9d1cc7356181f6f6c0aa2a5e92ad7174f09fa539" +_glaze_ver="7.7.1" +source=("${pkgname}-${pkgver}.tar.gz::https://github.com/FrogTheFrog/moondeck-buddy/archive/refs/tags/v${pkgver}.tar.gz" + "moondeck-keys-${_keys_commit}.tar.gz::https://github.com/FrogTheFrog/moondeck-keys/archive/${_keys_commit}.tar.gz" + "glaze-${_glaze_ver}.tar.gz::https://github.com/stephenberry/glaze/archive/refs/tags/v${_glaze_ver}.tar.gz") +sha256sums=('f68aff3e26c51618bd78e7656cfe3481fd0c4d2be377a26fc4e5db54e9541642' '80438b7cec54f89e3b03ad4bf1bf46edd36a8438e5ebcdb5333ecacd45aba7cc' 'c51217ca374f2a7d556c501a849d3a43dfffff47ba7711b6f0c22020e71ff63d') + +prepare() { + cd "moondeck-buddy-${pkgver}" + + rm -rf resources/ssl + ln -s "$srcdir/moondeck-keys-${_keys_commit}" resources/ssl + + # upstream builds with -Werror against GCC 13 and Qt 6.8; warnings that a + # newer toolchain adds must not fail the package build + sed -i 's/ -Werror)/)/' CMakeLists.txt +} + +build() { + cmake -B build -S "moondeck-buddy-${pkgver}" -G Ninja \ + -DCMAKE_BUILD_TYPE=None \ + -DCMAKE_INSTALL_PREFIX=/usr \ + -DFETCHCONTENT_FULLY_DISCONNECTED=ON \ + -DFETCHCONTENT_SOURCE_DIR_GLAZE="$srcdir/glaze-${_glaze_ver}" + cmake --build build +} + +package() { + # both binaries, the desktop entry and the icons + DESTDIR="$pkgdir" cmake --install build + + install -Dm644 "moondeck-buddy-${pkgver}/LICENSE" \ + "$pkgdir/usr/share/licenses/$pkgname/LICENSE" + install -Dm644 "glaze-${_glaze_ver}/LICENSE" \ + "$pkgdir/usr/share/licenses/$pkgname/LICENSE.glaze" +} diff --git a/moondeckbuddy/pkg.sh b/moondeckbuddy/pkg.sh new file mode 100644 index 0000000..50fdd91 --- /dev/null +++ b/moondeckbuddy/pkg.sh @@ -0,0 +1,54 @@ +# moondeckbuddy - MoonDeck Buddy (https://github.com/FrogTheFrog/moondeck-buddy), +# the host-side companion of the MoonDeck Steam Deck plugin (C++23 + Qt6). +# +# Source package: the PKGBUILD builds the release tag against Arch's Qt6 - the +# same CMake project upstream hands to linuxdeploy for the AppImage that +# moondeckbuddy-bin repackages. +# +# The tag tarball lacks two inputs of the build, both pinned per release: +# - resources/ssl is a git submodule (FrogTheFrog/moondeck-keys) holding the +# self-signed certificate compiled into Buddy; its commit is read from the +# tag's tree. +# - glaze is pulled by src/lib/json/CMakeLists.txt with FetchContent at +# configure time; its GIT_TAG is read from that file, and the PKGBUILD points +# FETCHCONTENT_SOURCE_DIR_GLAZE at the matching tarball so build() needs no +# network. +# +# Releases are created as drafts by upstream's CI and published by hand, so +# /releases/latest never points at a half-finished release. + +UPSTREAM_REPO="FrogTheFrog/moondeck-buddy" + +# Installed in CI (pacman) before the makepkg test build. +BUILD_DEPS=(cmake ninja procps-ng qt6-base qt6-httpserver qt6-websockets) + +latest_version() { + gh api "repos/$UPSTREAM_REPO/releases/latest" --jq '.tag_name' | sed 's/^v//' +} + +# refresh_checksums +refresh_checksums() { + local ver="$1" pkgbuild="$2" + local keys glaze sha_src sha_keys sha_glaze + + keys="$(gh api "repos/$UPSTREAM_REPO/contents/resources/ssl?ref=v$ver" --jq '.sha')" + glaze="$(gh api "repos/$UPSTREAM_REPO/contents/src/lib/json/CMakeLists.txt?ref=v$ver" \ + -H 'Accept: application/vnd.github.raw' | grep -Po 'GIT_TAG\s+v\K[0-9.]+$')" + if [[ ! "$keys" =~ ^[0-9a-f]{40}$ || -z "$glaze" ]]; then + echo "could not resolve the moondeck-keys commit ($keys) or glaze version ($glaze) of v$ver" >&2 + return 1 + fi + + sha_src="$(curl -sfL "https://github.com/$UPSTREAM_REPO/archive/refs/tags/v$ver.tar.gz" \ + | sha256sum | cut -d' ' -f1)" + sha_keys="$(curl -sfL "https://github.com/FrogTheFrog/moondeck-keys/archive/$keys.tar.gz" \ + | sha256sum | cut -d' ' -f1)" + sha_glaze="$(curl -sfL "https://github.com/stephenberry/glaze/archive/refs/tags/v$glaze.tar.gz" \ + | sha256sum | cut -d' ' -f1)" + + sed -i \ + -e "s|^_keys_commit=.*|_keys_commit=\"$keys\"|" \ + -e "s|^_glaze_ver=.*|_glaze_ver=\"$glaze\"|" \ + -e "s|^sha256sums=.*|sha256sums=('$sha_src' '$sha_keys' '$sha_glaze')|" \ + "$pkgbuild" +}