mirror of
https://github.com/theupriser/steamify-cachyos-live-iso.git
synced 2026-10-02 15:10:26 +02:00
feat: packagechooserq is built with the ISO (build-calamares-modules.sh) instead of a committed .so; the Steamify page is left out when Calamares' version differs from the one it was built for
This commit is contained in:
1 parent
ad246253c7
commit
62402ce4c8
6 files changed
+78
-21
No files matched your search
@@ -26,3 +26,4 @@ archiso/airootfs/usr/lib/libboost_*
|
|||||||
archiso/airootfs/etc/steammachine-iso-build
|
archiso/airootfs/etc/steammachine-iso-build
|
||||||
archiso/airootfs/usr/lib/modules/
|
archiso/airootfs/usr/lib/modules/
|
||||||
archiso/airootfs/etc/modules-load.d/steamify-fremont-poweroff.conf
|
archiso/airootfs/etc/modules-load.d/steamify-fremont-poweroff.conf
|
||||||
|
archiso/airootfs/usr/lib/calamares/modules/packagechooserq/
|
||||||
@@ -4,24 +4,19 @@
|
|||||||
|
|
||||||
1. **Steamify installer page** (2026-09-28, working end to end; see
|
1. **Steamify installer page** (2026-09-28, working end to end; see
|
||||||
`AGENTS.md` for the module/build/testing details and gotchas behind
|
`AGENTS.md` for the module/build/testing details and gotchas behind
|
||||||
this). `packagechooserq` (custom QML) is built out of tree and baked
|
this). `packagechooserq` (custom QML) is built with each ISO by
|
||||||
straight into `archiso/airootfs/usr/lib/calamares/modules/packagechooserq/`.
|
`build-calamares-modules.sh` into `archiso/airootfs/usr/lib/calamares/modules/packagechooserq/`.
|
||||||
`netinstall` (checkbox tree) stays as a manually-swappable fallback
|
`netinstall` (checkbox tree) stays as a manually-swappable fallback
|
||||||
(`steamify-cachyos-dev/share/sn.sh` + `nisteamify.conf`) for when the
|
(`steamify-cachyos-dev/share/sn.sh` + `nisteamify.conf`) for when the
|
||||||
module can't load, but isn't wired into `calamares-online.sh`
|
module can't load, but isn't wired into `calamares-online.sh`
|
||||||
automatically yet.
|
automatically yet.
|
||||||
- **Still open**:
|
- **Still open**:
|
||||||
- Bake the `packagechooserq` *build* into the ISO build pipeline
|
- The Summary step shows raw ids ("Install option: gaming,theme,...")
|
||||||
itself (a `build-calamares-modules.sh` step: install
|
for the Steamify page: the `prettyStatus()` override described in
|
||||||
`cachyos-calamares-next`, build out of tree, install into
|
`AGENTS.md` (labels from `items.json`) was never in the committed
|
||||||
`airootfs`) instead of committing a prebuilt `.so`, so it always
|
`.so` (it has no `items.json` string) and its source is lost. Add it
|
||||||
matches whatever Calamares version is current at build time.
|
as a patch that `build-calamares-modules.sh` applies to
|
||||||
- Version-mismatch fallback: after `calamares-online.sh`'s
|
`PackageChooserQmlViewStep.cpp`.
|
||||||
`pacman -Sy cachyos-calamares-next`, check the installed version
|
|
||||||
against what the module was built for; on a mismatch, switch
|
|
||||||
`settings.conf` to the `netinstall` page instead (generate its
|
|
||||||
groups conf from `--defaults --list` there too) rather than risk an
|
|
||||||
"Initialization Failed" module.
|
|
||||||
- "Boot into gaming mode" as an opt-out sub-toggle under SteamOS
|
- "Boot into gaming mode" as an opt-out sub-toggle under SteamOS
|
||||||
conversion (agreed with the user) isn't implemented on either page
|
conversion (agreed with the user) isn't implemented on either page
|
||||||
yet — both still use the old Gaming/Desktop radio-row.
|
yet — both still use the old Gaming/Desktop radio-row.
|
||||||
@@ -54,6 +49,12 @@
|
|||||||
|
|
||||||
## Done
|
## Done
|
||||||
|
|
||||||
|
- **packagechooserq built with the ISO** (2026-09-28):
|
||||||
|
`build-calamares-modules.sh` builds it in the build container/VM from
|
||||||
|
CachyOS's Calamares source against the current `cachyos-calamares-next`
|
||||||
|
(no prebuilt `.so` in git), with `built-for`; `calamares-online.sh` leaves
|
||||||
|
the Steamify page out when the Calamares it runs differs (the step then
|
||||||
|
installs everything on) instead of risking "Initialization Failed".
|
||||||
- **Steamify 2.6.0** released (`--defaults`, install-time mode).
|
- **Steamify 2.6.0** released (`--defaults`, install-time mode).
|
||||||
- **Live session** (VM, `--fremont`): Vapor look and layout (Steam Deck
|
- **Live session** (VM, `--fremont`): Vapor look and layout (Steam Deck
|
||||||
wallpaper) at the live login; the power-off module is built for both ISO
|
wallpaper) at the live login; the power-off module is built for both ISO
|
||||||
|
|||||||
BIN
Binary file not shown.
@@ -1,7 +0,0 @@
|
|||||||
# AUTO-GENERATED metadata file
|
|
||||||
# Syntax is YAML 1.2
|
|
||||||
---
|
|
||||||
type: "viewmodule"
|
|
||||||
name: "packagechooserq"
|
|
||||||
interface: "qtplugin"
|
|
||||||
load: "libcalamares_viewmodule_packagechooserq.so"
|
|
||||||
@@ -83,8 +83,21 @@ EOF
|
|||||||
# Steamify: its page (packagechooserq@steamifypage, right after the
|
# Steamify: its page (packagechooserq@steamifypage, right after the
|
||||||
# packages page) and its step (modules/shellprocess_steamify.conf) before
|
# packages page) and its step (modules/shellprocess_steamify.conf) before
|
||||||
# the installer cleans up after itself.
|
# the installer cleans up after itself.
|
||||||
|
# The page's module is built for one cachyos-calamares-next
|
||||||
|
# (build-calamares-modules.sh); the pacman -Sy above may have brought
|
||||||
|
# another, which it might not load in ("Initialization Failed" blocks the
|
||||||
|
# installer). Then leave the page out: the step installs the page's
|
||||||
|
# default, everything on.
|
||||||
|
local built installed
|
||||||
|
built="$(cat /usr/lib/calamares/modules/packagechooserq/built-for 2>/dev/null)"
|
||||||
|
installed="$(pacman -Q cachyos-calamares-next | cut -d' ' -f2)"
|
||||||
|
local page=(-e 's/^ - netinstall$/&\n - packagechooserq@steamifypage/')
|
||||||
|
if [[ -z "$built" || "$built" != "$installed" ]]; then
|
||||||
|
echo "Steamify page left out: built for cachyos-calamares-next ${built:-?}, running $installed." >> "$log"
|
||||||
|
page=()
|
||||||
|
fi
|
||||||
sudo sed -i -e 's/^- id: cleanup_calamares$/- id: steamifypage\n module: packagechooserq\n config: packagechooserq_steamifypage.conf\n\n- id: steamify\n module: shellprocess\n config: shellprocess_steamify.conf\n\n&/' \
|
sudo sed -i -e 's/^- id: cleanup_calamares$/- id: steamifypage\n module: packagechooserq\n config: packagechooserq_steamifypage.conf\n\n- id: steamify\n module: shellprocess\n config: shellprocess_steamify.conf\n\n&/' \
|
||||||
-e 's/^ - netinstall$/&\n - packagechooserq@steamifypage/' \
|
"${page[@]}" \
|
||||||
-e 's/^ - shellprocess@cleanup_calamares$/ - shellprocess@steamify\n&/' /etc/calamares/settings.conf
|
-e 's/^ - shellprocess@cleanup_calamares$/ - shellprocess@steamify\n&/' /etc/calamares/settings.conf
|
||||||
exec pkexec-wrapper calamares -D6 >> $log
|
exec pkexec-wrapper calamares -D6 >> $log
|
||||||
}
|
}
|
||||||
|
|||||||
Executable
+49
@@ -0,0 +1,49 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
# build-calamares-modules.sh: builds Calamares' packagechooserq module (the
|
||||||
|
# QML page the Steamify page runs in) for the ISO. CachyOS's
|
||||||
|
# cachyos-calamares-next leaves it out of its own build, so it's built here,
|
||||||
|
# out of tree, from CachyOS's Calamares source against the installed
|
||||||
|
# cachyos-calamares-next, and installed into airootfs. Run as root in the
|
||||||
|
# build container, before buildiso.sh: the package comes from the same repos
|
||||||
|
# at the same time as the ISO's, so the module matches the ISO's Calamares.
|
||||||
|
# Records the version it was built for next to it (calamares-online.sh
|
||||||
|
# compares that with the Calamares it ends up with).
|
||||||
|
set -euo pipefail
|
||||||
|
cd "$(dirname "$0")"
|
||||||
|
dest=archiso/airootfs/usr/lib/calamares/modules/packagechooserq
|
||||||
|
src_url=https://github.com/CachyOS/cachyos-calamares/archive/refs/heads/cachyos.tar.gz
|
||||||
|
|
||||||
|
pacman -S --needed --noconfirm cachyos-calamares-next cmake extra-cmake-modules \
|
||||||
|
qt6-declarative qt6-tools qt6-svg kcoreaddons yaml-cpp base-devel >/dev/null
|
||||||
|
work="$(mktemp -d)"
|
||||||
|
mkdir -p "$work/src" "$work/cmake"
|
||||||
|
# The module and the packagechooser sources it shares (Config, PackageModel),
|
||||||
|
# plus the CMake helper its CMakeLists includes, which Calamares doesn't install.
|
||||||
|
curl -fsSL "$src_url" -o "$work/calamares.tar.gz"
|
||||||
|
tar -xzf "$work/calamares.tar.gz" --strip-components=3 -C "$work/src" \
|
||||||
|
cachyos-calamares-cachyos/src/modules/packagechooserq cachyos-calamares-cachyos/src/modules/packagechooser
|
||||||
|
tar -xzf "$work/calamares.tar.gz" --strip-components=2 -C "$work/cmake" \
|
||||||
|
cachyos-calamares-cachyos/CMakeModules/AppStreamHelper.cmake
|
||||||
|
# KF6CoreAddons before Calamares: Calamares' CMake config needs its target.
|
||||||
|
cat > "$work/src/CMakeLists.txt" << EOF
|
||||||
|
cmake_minimum_required(VERSION 3.16)
|
||||||
|
project(steamify_packagechooserq LANGUAGES CXX)
|
||||||
|
set(WITH_QML ON)
|
||||||
|
set(WITH_QT6 ON)
|
||||||
|
set(qtname Qt6)
|
||||||
|
set(QT_VERSION_SUFFIX -qt6)
|
||||||
|
find_package(ECM REQUIRED NO_MODULE)
|
||||||
|
set(CMAKE_MODULE_PATH \${ECM_MODULE_PATH} /usr/lib/cmake/Calamares $work/cmake \${CMAKE_MODULE_PATH})
|
||||||
|
find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets Qml Quick)
|
||||||
|
find_package(KF6CoreAddons REQUIRED)
|
||||||
|
find_package(Calamares REQUIRED)
|
||||||
|
add_subdirectory(packagechooserq)
|
||||||
|
EOF
|
||||||
|
cmake -S "$work/src" -B "$work/build" -DCMAKE_BUILD_TYPE=Release > "$work/cmake.log" 2>&1 ||
|
||||||
|
{ tail -30 "$work/cmake.log"; exit 1; }
|
||||||
|
make -s -C "$work/build" -j"$(nproc)"
|
||||||
|
install -Dm755 "$work/build/packagechooserq/libcalamares_viewmodule_packagechooserq.so" "$dest/libcalamares_viewmodule_packagechooserq.so"
|
||||||
|
install -Dm644 "$work/build/packagechooserq/module.desc" "$dest/module.desc"
|
||||||
|
pacman -Q cachyos-calamares-next | cut -d' ' -f2 > "$dest/built-for"
|
||||||
|
rm -rf "$work"
|
||||||
|
echo "packagechooserq built for cachyos-calamares-next $(cat "$dest/built-for")."
|
||||||
Reference in new issue
Block a user