%undefine _hardened_build %undefine _include_frame_pointers %define _fortify_level 2 %define upstream_version 0.18-1 Name: procwatch Version: %{lua:ver = string.gsub(rpm.expand("%{upstream_version}"), "-", "~"); print(ver)} Release: 1%{?dist} Summary: Process watcher License: GPLv3+ URL: https://betaco.de/strom/%{name} Source: %{url}/archive/%{name}-%{upstream_version}.tar.gz BuildRequires: gcc-c++ BuildRequires: meson BuildRequires: pkgconfig(CLI11) BuildRequires: pkgconfig(re2) BuildRequires: pkgconfig(libnotify) BuildRequires: systemd-rpm-macros %description Monitor CPU usage of processes matching a regular expression pattern %prep %autosetup -p1 -n %{name} %build %ifarch x86_64 export CXXFLAGS="$CXXFLAGS -march=x86-64-v3" %endif %meson %meson_build %install %meson_install install -D -pv -m0644 -t %{buildroot}%{_userunitdir} systemd/%{name}.service %post %systemd_user_post %{name}.service %preun %systemd_user_preun %{name}.service %postun %systemd_user_postun_with_restart %{name}.service %systemd_user_postun_with_reload %{name}.service %systemd_user_postun %{name}.service %files %license LICENSE %doc README.md %{_bindir}/%{name} %{_mandir}/man1/%{name}.1* %{_userunitdir}/%{name}.service %changelog * Sat Oct 26 2024 Thorsten Schubert - %{version}-%{release} - Reduce allocations * Thu Oct 24 2024 Thorsten Schubert - %{version}-%{release} - Initial package build