mirror of
https://github.com/Andre-Bzk/twitch4steamdeck.git
synced 2026-11-15 15:43:08 +01:00
Phase 6 Fix 1
- Flatpak build erfolgreich - Auf Steamdeck lauffähig - Stream obder VOD Wiedergabe nicht möglich
This commit is contained in:
@@ -9,6 +9,22 @@ PROJECT_DIR="$(cd "$SCRIPT_DIR/.." && pwd)"
|
|||||||
cd "$PROJECT_DIR"
|
cd "$PROJECT_DIR"
|
||||||
echo "=== Arbeitsverzeichnis: $PROJECT_DIR ==="
|
echo "=== Arbeitsverzeichnis: $PROJECT_DIR ==="
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
|
# WSL2-Dateisystem-Check: flatpak-builder kann nicht über /mnt/ (Windows 9P) bauen
|
||||||
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
|
if [[ "$PROJECT_DIR" == /mnt/* ]]; then
|
||||||
|
echo ""
|
||||||
|
echo "FEHLER: Das Projekt liegt auf dem Windows-Dateisystem ($PROJECT_DIR)."
|
||||||
|
echo " flatpak-builder benötigt FUSE, das auf /mnt/ nicht funktioniert."
|
||||||
|
echo ""
|
||||||
|
echo " Lösung: Projekt auf das Linux-Dateisystem kopieren und von dort bauen:"
|
||||||
|
echo " cp -rp /mnt/c/Projekte/twitch4steamdeck ~/twitch4steamdeck"
|
||||||
|
echo " cd ~/twitch4steamdeck"
|
||||||
|
echo " bash flatpak/build-flatpak.sh"
|
||||||
|
echo ""
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
# Schritt 1: Flatpak-Abhängigkeiten prüfen
|
# Schritt 1: Flatpak-Abhängigkeiten prüfen
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
@@ -123,6 +139,7 @@ flatpak-builder \
|
|||||||
--user \
|
--user \
|
||||||
--install \
|
--install \
|
||||||
--force-clean \
|
--force-clean \
|
||||||
|
--disable-rofiles-fuse \
|
||||||
build-dir \
|
build-dir \
|
||||||
flatpak/tv.twitch4steamdeck.App.yml
|
flatpak/tv.twitch4steamdeck.App.yml
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,8 @@
|
|||||||
|
--- a/audio/decode/ad_spdif.c
|
||||||
|
+++ b/audio/decode/ad_spdif.c
|
||||||
|
@@ -165,7 +165,7 @@ static int init_filter(struct dec_audio *da, AVCodec *codec)
|
||||||
|
|
||||||
|
-static int write_packet(void *opaque, uint8_t *buf, int buf_size)
|
||||||
|
+static int write_packet(void *opaque, const uint8_t *buf, int buf_size)
|
||||||
|
{
|
||||||
|
struct spdif_filter *sf = opaque;
|
||||||
@@ -29,14 +29,47 @@ finish-args:
|
|||||||
|
|
||||||
modules:
|
modules:
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
# 1) mpv — Media-Player für Live-Streams und VODs
|
# 1a) libass — Untertitel-Rendering (nicht im freedesktop SDK 24.08 enthalten)
|
||||||
# Gebaut aus Sources; libplacebo deaktiviert (entfernt Vulkan/Shader-Chain).
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
# ffmpeg, libass und libva (VAAPI) kommen aus dem freedesktop SDK 24.08.
|
- name: libass
|
||||||
|
config-opts:
|
||||||
|
- --disable-static
|
||||||
|
- --libdir=/app/lib
|
||||||
|
sources:
|
||||||
|
- type: archive
|
||||||
|
url: https://github.com/libass/libass/releases/download/0.17.3/libass-0.17.3.tar.gz
|
||||||
|
sha256: da7c348deb6fa6c24507afab2dee7545ba5dd5bbf90a137bfe9e738f7df68537
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
|
# 1b) libplacebo — Pflicht-Abhängigkeit für mpv 0.38+ (gpu-next renderer)
|
||||||
|
# vulkan=disabled: kein Vulkan-Renderer, OpenGL/EGL+VAAPI reicht für uns.
|
||||||
|
# shaderc + lcms2 kommen aus dem freedesktop SDK 24.08.
|
||||||
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
|
- name: libplacebo
|
||||||
|
buildsystem: meson
|
||||||
|
config-opts:
|
||||||
|
- -Dlibdir=lib
|
||||||
|
- -Dvulkan=disabled
|
||||||
|
- -Dglslang=disabled
|
||||||
|
- -Dshaderc=enabled
|
||||||
|
- -Dlcms=enabled
|
||||||
|
- -Ddemos=false
|
||||||
|
- -Dtests=false
|
||||||
|
sources:
|
||||||
|
- type: archive
|
||||||
|
# Lokaler Tarball mit glad2-Submodul (GitHub-Tarball enthält Submodule nicht).
|
||||||
|
# Erstellen: siehe flatpak/build-flatpak.sh oder README.
|
||||||
|
# In WSL2: liegt unter ~/twitch4steamdeck/flatpak/libplacebo-6.338.2-full.tar.gz
|
||||||
|
path: libplacebo-6.338.2-full.tar.gz
|
||||||
|
sha256: 7f5da41b872302208f0e10c22d3e108ab9fdb1f253eb47c18651698c65d6b426
|
||||||
|
|
||||||
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
|
# 1c) mpv — Media-Player für Live-Streams und VODs
|
||||||
|
# ffmpeg, libass, libplacebo, libva (VAAPI) verfügbar.
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
- name: mpv
|
- name: mpv
|
||||||
buildsystem: meson
|
buildsystem: meson
|
||||||
config-opts:
|
config-opts:
|
||||||
- -Dlibplacebo=disabled
|
|
||||||
- -Dvaapi=enabled
|
- -Dvaapi=enabled
|
||||||
- -Dpulse=enabled
|
- -Dpulse=enabled
|
||||||
- -Dalsa=disabled
|
- -Dalsa=disabled
|
||||||
@@ -48,9 +81,7 @@ modules:
|
|||||||
sources:
|
sources:
|
||||||
- type: archive
|
- type: archive
|
||||||
url: https://github.com/mpv-player/mpv/archive/refs/tags/v0.38.0.tar.gz
|
url: https://github.com/mpv-player/mpv/archive/refs/tags/v0.38.0.tar.gz
|
||||||
# sha256 generieren: sha256sum mpv-0.38.0.tar.gz
|
sha256: 86d9ef40b6058732f67b46d0bbda24a074fae860b3eaae05bab3145041303066
|
||||||
# oder: curl -L <url> | sha256sum
|
|
||||||
sha256: FILL_IN_sha256sum_of_mpv_0.38.0_tarball
|
|
||||||
|
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
# 2) streamlink (Python) — liefert HLS-URLs aus Twitch-Streams
|
# 2) streamlink (Python) — liefert HLS-URLs aus Twitch-Streams
|
||||||
@@ -77,14 +108,10 @@ modules:
|
|||||||
- type: archive
|
- type: archive
|
||||||
url: https://github.com/streamlink/streamlink/archive/refs/tags/6.11.0.tar.gz
|
url: https://github.com/streamlink/streamlink/archive/refs/tags/6.11.0.tar.gz
|
||||||
# sha256 generieren: sha256sum streamlink-6.11.0.tar.gz
|
# sha256 generieren: sha256sum streamlink-6.11.0.tar.gz
|
||||||
sha256: FILL_IN_sha256sum_of_streamlink_tarball
|
sha256: fbed984049b33f176e3a63e4bce302180d1ef24feffa24ea7306aad1a24bff40
|
||||||
# ACHTUNG: Vor dem echten Build alle Python-Dependencies (requests, websocket-client,
|
# ACHTUNG: Vor dem echten Release-Build alle Python-Dependencies (requests,
|
||||||
# pycountry, pycryptodome, ...) mit flatpak-pip-generator als separate file-Sources
|
# websocket-client, pycountry, pycryptodome, ...) mit flatpak-pip-generator
|
||||||
# einbinden. Sonst schlägt der offline Build fehl.
|
# als separate file-Sources einbinden. Sonst ist Streamlink zur Laufzeit unvollständig.
|
||||||
# Kurzfristig: 'build-network-access: true' setzen um online-pip zu nutzen (nur lokal!).
|
|
||||||
build-options:
|
|
||||||
build-args:
|
|
||||||
- --allow-network-access
|
|
||||||
|
|
||||||
# ─────────────────────────────────────────────────────────────────────────────
|
# ─────────────────────────────────────────────────────────────────────────────
|
||||||
# 3) Haupt-App
|
# 3) Haupt-App
|
||||||
@@ -123,6 +150,23 @@ modules:
|
|||||||
# .desktop-Eintrag
|
# .desktop-Eintrag
|
||||||
- install -Dm644 flatpak/tv.twitch4steamdeck.App.desktop \
|
- install -Dm644 flatpak/tv.twitch4steamdeck.App.desktop \
|
||||||
/app/share/applications/tv.twitch4steamdeck.App.desktop
|
/app/share/applications/tv.twitch4steamdeck.App.desktop
|
||||||
|
# WSL/Windows-Checkouts können 0777 an viele Dateien vererben; OSTree lehnt das ab.
|
||||||
|
- find /app -type d -exec chmod 755 {} +
|
||||||
|
- find /app -type f -exec chmod 644 {} +
|
||||||
|
- find /app/bin -type f -exec chmod 755 {} +
|
||||||
|
- find /app/lib -type f -name '*.so*' -exec chmod 755 {} +
|
||||||
|
- |
|
||||||
|
if [ -d /app/libexec ]; then
|
||||||
|
find /app/libexec -type f -exec chmod 755 {} +
|
||||||
|
fi
|
||||||
|
- |
|
||||||
|
if [ -f /app/lib/twitch4steamdeck/node_modules/electron/dist/electron ]; then
|
||||||
|
chmod 755 /app/lib/twitch4steamdeck/node_modules/electron/dist/electron
|
||||||
|
fi
|
||||||
|
- |
|
||||||
|
if [ -f /app/lib/twitch4steamdeck/node_modules/electron/dist/chrome-sandbox ]; then
|
||||||
|
chmod 755 /app/lib/twitch4steamdeck/node_modules/electron/dist/chrome-sandbox
|
||||||
|
fi
|
||||||
sources:
|
sources:
|
||||||
# Gesamtes Projektverzeichnis (inkl. aus/ + node_modules/ aus WSL2-Prebuild)
|
# Gesamtes Projektverzeichnis (inkl. aus/ + node_modules/ aus WSL2-Prebuild)
|
||||||
- type: dir
|
- type: dir
|
||||||
|
|||||||
@@ -82,7 +82,13 @@ twitch4steamdeck/
|
|||||||
├── electron-builder.yml ✅
|
├── electron-builder.yml ✅
|
||||||
├── .env.example ✅
|
├── .env.example ✅
|
||||||
├── flatpak/
|
├── flatpak/
|
||||||
│ └── tv.twitch4steamdeck.App.yml ⏳ Phase 6
|
│ ├── tv.twitch4steamdeck.App.yml ✅ Phase 6
|
||||||
|
│ ├── twitch4steamdeck.sh ✅ Phase 6
|
||||||
|
│ ├── tv.twitch4steamdeck.App.desktop ✅ Phase 6
|
||||||
|
│ └── build-flatpak.sh ✅ Phase 6
|
||||||
|
├── resources/
|
||||||
|
│ └── icons/
|
||||||
|
│ └── icon.svg ✅ Phase 6 (Platzhalter)
|
||||||
├── src/
|
├── src/
|
||||||
│ ├── main/
|
│ ├── main/
|
||||||
│ │ ├── index.ts ✅ (Auth + Helix instanziiert)
|
│ │ ├── index.ts ✅ (Auth + Helix instanziiert)
|
||||||
@@ -255,11 +261,15 @@ CREATE INDEX IF NOT EXISTS idx_history_watched ON vod_history(watched_at DESC);
|
|||||||
- `LanguageBadge` rendert in Thumbnails: unten-rechts (gegenüber Viewer-Count unten-links)
|
- `LanguageBadge` rendert in Thumbnails: unten-rechts (gegenüber Viewer-Count unten-links)
|
||||||
- 38 Sprachen gemappt (pragmatische Twitch-Dominanz: `pt→🇧🇷`, `en→🇺🇸`, `zh→🇹🇼`)
|
- 38 Sprachen gemappt (pragmatische Twitch-Dominanz: `pt→🇧🇷`, `en→🇺🇸`, `zh→🇹🇼`)
|
||||||
|
|
||||||
### Flatpak (⏳ Phase 6)
|
### Flatpak (✅ Phase 6 — Dateien erstellt, Verifikation auf Steam Deck ausstehend)
|
||||||
- Runtime: `org.freedesktop.Platform//23.08`, `org.electronjs.Electron2.BaseApp`
|
- Runtime: `org.freedesktop.Platform//24.08`, `org.electronjs.Electron2.BaseApp//24.08`
|
||||||
- Module: app-bundle, `mpv`, `streamlink` (pip), evtl. `streamlink-ttvlol`
|
- Module: `mpv` (aus Sources, libplacebo disabled), `streamlink` (pip), App-Bundle
|
||||||
- Permissions: `--share=network`, `--share=ipc`, `--socket=wayland`, `--socket=fallback-x11`,
|
- Permissions: `--share=network`, `--share=ipc`, `--socket=wayland`, `--socket=fallback-x11`,
|
||||||
`--socket=pulseaudio`, `--device=dri`
|
`--socket=pulseaudio`, `--device=dri`
|
||||||
|
- Pre-Build-Strategie: `npm install` + `@electron/rebuild` + `npm run build` in WSL2,
|
||||||
|
dann Artefakte per `type:dir` Source ins Flatpak kopieren
|
||||||
|
- Launcher: `zypak-wrapper node_modules/electron/dist/electron out/main/index.js`
|
||||||
|
- Build-Skript: `flatpak/build-flatpak.sh` (WSL2, prüft deps, füllt SHA256, baut)
|
||||||
|
|
||||||
## Verifikation
|
## Verifikation
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user