From ca970e927f37cfbafdb83dff10cb8a116871cd6b Mon Sep 17 00:00:00 2001 From: metcya Date: Mon, 5 Jan 2026 16:49:32 -0600 Subject: [PATCH] fix versioning --- anda/apps/sunshine/ci_setup.rhai | 2 ++ anda/apps/sunshine/sunshine.spec | 51 ++++++++++++++++++++++++++++++-- 2 files changed, 50 insertions(+), 3 deletions(-) create mode 100644 anda/apps/sunshine/ci_setup.rhai diff --git a/anda/apps/sunshine/ci_setup.rhai b/anda/apps/sunshine/ci_setup.rhai new file mode 100644 index 0000000000..5f355578a2 --- /dev/null +++ b/anda/apps/sunshine/ci_setup.rhai @@ -0,0 +1,2 @@ +import "andax/ci/nvidia.rhai" as extra_repos; +extra_repos::install(labels); diff --git a/anda/apps/sunshine/sunshine.spec b/anda/apps/sunshine/sunshine.spec index d6817e5348..4c54685496 100644 --- a/anda/apps/sunshine/sunshine.spec +++ b/anda/apps/sunshine/sunshine.spec @@ -1,9 +1,14 @@ %bcond_without cuda +%bcond_without check + +%global appid dev.lizardbyte.app.Sunshine +%global github_url https://github.com/LizardByte/Sunshine.git +%global commit 86188d47a7463b0f73b35de18a628353adeaa20e Name: sunshine Version: 2025.924.154138 Release: 1%{?dist} -License: GPL-3.0-Only +License: GPL-3.0-only AND CC0-1.0 URL: http://app.lizardbyte.dev/Sunshine/ Patch0: fix-test-cxxflags.patch Summary: Self-hosted game stream host for Moonlight @@ -13,6 +18,7 @@ BuildRequires: anda-srpm-macros BuildRequires: cmake BuildRequires: gcc-c++ BuildRequires: openssl-devel +BuildRequires: boost-devel BuildRequires: pkgconfig(libcap) BuildRequires: pkgconfig(libdrm) BuildRequires: pkgconfig(libva) @@ -37,11 +43,17 @@ BuildRequires: pkgconfig(libpulse) BuildRequires: pkgconfig(numa) BuildRequires: doxygen BuildRequires: nodejs-npm +BuildRequires: systemd-rpm-macros %if %{with cuda} BuildRequires: cuda %endif +%if %{with check} +BuildRequires: appstream +BuildRequires: desktop-file-utils +%endif + %description Sunshine is a self-hosted game stream host for Moonlight. Offering low-latency, cloud gaming server capabilities with support for AMD, Intel, and Nvidia GPUs @@ -51,17 +63,50 @@ provided to allow configuration, and client pairing, from your favorite web browser. Pair from the local server or any mobile device. %prep -%git_clone https://github.com/LizardByte/Sunshine.git v%{version} +%git_clone %{github_url} v%{version} %autopatch -p1 %build -%cmake -DSUNSHINE_ENABLE_CUDA=%{?with_cuda:ON:OFF} +export BRANCH=master +export BUILD_VERSION=%{version} +export CLONE_URL=%{github_url} +export COMMIT=%{commit} +export TAG=v%{version} +%cmake -DSUNSHINE_ENABLE_CUDA=%{?with_cuda:ON:OFF} \ + -DSUNSHINE_ASSETS_DIR=share/%{name} %cmake_build %install %cmake_install +%terra_appstream + +%post +%systemd_post %{name}.service + +%preun +%systemd_preun %{name}.service + +%postun +%systemd_postun_with_restart %{name}.service + +%if %{with check} +%check +appstreamcli validate %{buildroot}%{_metainfodir}/%{appid}.metainfo.xml +desktop-file-validate %{buildroot}%{_appsdir}/%{appid}{,.terminal}.desktop +%endif + %files +%{_bindir}/%{name} +%{_bindir}/%{name}-%{version} +%{_datadir}/%{name}/ +%{_userunitdir}/%{name}.service +%{_udevrulesdir}/60-%{name}.rules +%{_modulesloaddir}/60-%{name}.conf +%{_hicolordir}/scalable/apps/%{name}.svg +%{_hicolordir}/scalable/status/*.svg +%{_appsdir}/*.desktop +%{_metainfodir}/%{appid}.metainfo.xml %changelog * Sun Jan 04 2026 metcya - 2025.924.154138-1