File amd-bc-250-gpu-governor.spec of Package amd-bc-250-gpu-governor
#
# spec file for package amd-bc-250-gpu-governor
#
# Copyright (c) 2025 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via https://bugs.opensuse.org/
#
Name: amd-bc-250-gpu-governor
Version: 0.2.0
Release: 1
Summary: A daemon for AMD Cyan Skillfish systems that automatically governs GPU
License: MIT
URL: https://github.com/AMD-BC-250/gpu-governor
Source0: https://github.com/AMD-BC-250/gpu-governor/archive/refs/tags/%{version}.tar.gz#/%{name}-%{version}.tar.gz
BuildRequires: cmake
BuildRequires: gcc-c++
BuildRequires: libdrm-devel
BuildRequires: yaml-cpp-devel
BuildRequires: systemd
%description
A simple daemon for AMD Cyan Skillfish based systems that automatically governs GPU voltage and frequency based on load and temperature.
%prep
%setup -q -n gpu-governor-%{version}
%build
%cmake
%cmake_build
%install
%cmake_install
chmod 666 %{buildroot}/etc/%{name}.yaml
%pre
%service_add_pre %{name}.service
%post
%service_add_post %{name}.service
systemctl enable %{name}.service
systemctl start %{name}.service
%preun
%service_del_preun %{name}.service
%postun
%service_del_postun %{name}.service
%files
%config /etc/%{name}.yaml
%license LICENSE
%{_bindir}/%{name}
%{_unitdir}/%{name}.service
%changelog