Require system .NET SDK; cache vpk/ffmpeg persistently
release / gui-build (linux, bash) (push) Failing after 50s
release / gui-build (macos, bash) (push) Successful in 1m39s
release / gui-build (windows, cmd) (push) Failing after 1m40s

Per-build downloads of the dotnet runtime (~80 MB) were slow and flaky
(IncompleteRead killed a CI run). The .NET SDK is now a build-host
prerequisite; vpk and ffmpeg download once into a user-level cache
(~/.cache/mediahive-build, %LOCALAPPDATA%\mediahive-build) that
survives the per-run build dir.
This commit is contained in:
2026-09-23 00:28:11 +00:00
parent 37f786f5ed
commit f9002b19a2
3 changed files with 56 additions and 53 deletions
+11 -2
View File
@@ -5,8 +5,9 @@
# pyinstaller --noconfirm --clean scripts/MediaHive.spec
#
# Or use the build script (recommended—handles versioning and packaging):
# uv run scripts/winbuild.py
# uv run scripts/guibuild.py
import os
import sys
import mediahive.winmain
import mediahive.server
@@ -20,7 +21,15 @@ _frontend_build = _pkg / "frontend-build"
_logo_webp = _pkg / "assets" / "mediahive.webp"
_icon_win = _pkg / "assets" / "mediahive.ico"
_icon_mac = _pkg / "assets" / "mediahive.icns"
_tools_dir = Path(SPECPATH).parent / "build" / "ffmpeg"
# ffmpeg staging lives in the persistent build cache (same logic as
# scripts/guibuild.py); fall back to the legacy build/ffmpeg location.
if sys.platform == "win32":
_cache_base = Path(os.environ.get("LOCALAPPDATA", Path.home() / "AppData" / "Local"))
else:
_cache_base = Path(os.environ.get("XDG_CACHE_HOME", Path.home() / ".cache"))
_tools_dir = _cache_base / "mediahive-build" / "ffmpeg"
if not _tools_dir.exists():
_tools_dir = Path(SPECPATH).parent / "build" / "ffmpeg"
_tool_names = ["ffmpeg.exe"] if sys.platform == "win32" else ["ffmpeg"]
_binaries = []