Name: ananicy-cpp Version: 1.2.0 Release: 10%{?dist} Summary: ANother Auto NICe daemon — rewrite in C++ License: GPLv3 URL: https://gitlab.com/ananicy-cpp/ananicy-cpp Source0: https://gitlab.com/ananicy-cpp/ananicy-cpp/-/archive/v%{version}/ananicy-cpp-v%{version}.tar.gz ExcludeArch: s390x i686 ppc64le BuildRequires: gcc-c++ BuildRequires: cmake BuildRequires: ninja-build BuildRequires: systemd-devel BuildRequires: systemd-rpm-macros BuildRequires: zlib-devel BuildRequires: nlohmann-json-devel BuildRequires: fmt-devel BuildRequires: spdlog-devel %description Rewrite of ananicy in C++ — ajustement automatique des priorités CPU/IO de tous les processus selon une base de règles. Complémentaire à GameMode : ananicy-cpp est permanent et surveille tous les processus, pas seulement les jeux qui utilisent gamemoderun. %prep %autosetup -n ananicy-cpp-v%{version} # GCC 16 fix: nlohmann_json cmake target adds -isystem /usr/include which breaks # cstdlib's #include_next chain. Clear the system include property. python3 -c " content = open('CMakeLists.txt').read() fix = ''' # Fix GCC 16 stdlib.h: prevent nlohmann from injecting -isystem /usr/include if(TARGET nlohmann_json::nlohmann_json) set_property(TARGET nlohmann_json::nlohmann_json PROPERTY INTERFACE_SYSTEM_INCLUDE_DIRECTORIES \"\") endif() ''' content = content.replace( 'find_package(nlohmann_json 3.9 REQUIRED)', 'find_package(nlohmann_json 3.9 REQUIRED)' + fix) open('CMakeLists.txt', 'w').write(content) " %build %cmake \ -GNinja \ -DENABLE_SYSTEMD=ON \ -DUSE_BPF_PROC_IMPL=OFF \ -DUSE_EXTERNAL_JSON=ON \ -DUSE_EXTERNAL_FMTLIB=ON \ -DUSE_EXTERNAL_SPDLOG=ON \ -DENABLE_ANANICY_TESTS=OFF \ -DBUILD_SHARED_LIBS=OFF \ -DVERSION=%{version} \ -DCMAKE_CXX_FLAGS="-include unistd.h" \ -Dfmt_DIR=/usr/lib64/cmake/fmt \ -Dspdlog_DIR=/usr/lib64/cmake/spdlog %ninja_build -C %{_vpath_builddir} %install %ninja_install -C %{_vpath_builddir} %post %systemd_post ananicy-cpp.service %preun %systemd_preun ananicy-cpp.service %postun %systemd_postun_with_restart ananicy-cpp.service %files %license LICENSE %doc README.md %{_bindir}/ananicy-cpp %{_unitdir}/ananicy-cpp.service %changelog * Wed May 27 2026 ShivaOS Team - 1.2.0-10 - Fix GCC 16: nlohmann_json cmake target injectait -isystem /usr/include cassant cstdlib #include_next * Wed May 27 2026 ShivaOS Team - 1.2.0-9 - USE_BPF_PROC_IMPL=OFF : clang cross-compile cassait stdlib.h pour GCC - Suppression libbpf-devel, bpftool, elfutils, clang, llvm des BuildRequires * Wed May 27 2026 ShivaOS Team - 1.2.0-7 - Fix cmake fmt/spdlog : chemins explicites /usr/lib64/cmake/ * Wed May 27 2026 ShivaOS Team - 1.2.0-1 - ananicy-cpp 1.2.0 pour ShivaOS (systemd, sans BPF)