Name: flux-accounting Version: 0.55.0 Release: 1%{?dist} Summary: Bank/Accounting Interface for the Flux Resource Manager License: LGPL-3.0-only URL: https://github.com/flux-framework/flux-accounting Source0: %{url}/releases/download/v%{version}/%{name}-%{version}.tar.gz # Python 3.12+ compatibility: imp module was removed (PEP 594) # Backport of automake 1.16.5+ fix for py-compile Patch0: py-compile-python312.patch # Exclude flux Python subcommands from shebang mangling - these files are run # through the `flux python` wrapper and don't have shebangs by design. Without # this, brp-mangle-shebangs strips the executable bit we set, breaking `flux account`. %global __brp_mangle_shebangs_exclude_from ^%{_libexecdir}/flux/ BuildRequires: pkgconfig(jansson) >= 2.10 BuildRequires: pkgconfig(sqlite3) BuildRequires: python3 BuildRequires: python3-devel BuildRequires: python3-cffi BuildRequires: python3-pyyaml BuildRequires: python3-sphinx BuildRequires: python3-sphinx_rtd_theme BuildRequires: python3-docutils BuildRequires: flux-core BuildRequires: flux-core-devel BuildRequires: autoconf BuildRequires: automake BuildRequires: libtool BuildRequires: make BuildRequires: gcc BuildRequires: gcc-c++ # for _unitdir BuildRequires: systemd-rpm-macros # Required for en_US.UTF-8 locale during documentation build BuildRequires: glibc-langpack-en Requires: flux-core Requires: python3-flux Requires: sqlite >= 3.6.0 Requires: python3 Requires: python3-cffi Requires: python3-pyyaml %description Flux Framework is a suite of projects, tools and libraries which may be used to build site-custom resource managers at High Performance Computing sites. flux-accounting manages user/bank accounts and calculates and updates job priorities, job usage values, and fairshare values. It consists of a SQLite database and a set of libraries and front-end services to interact with this database. %prep %autosetup -n %{name}-%{version} -p1 %build export LC_ALL=en_US.UTF-8 %configure \ --with-systemdsystemunitdir=%{_unitdir} \ --disable-static %make_build %install %make_install # Remove libtool archives find %{buildroot} -name '*.la' -delete # Remove shebangs from non-executable Python modules to fix rpmlint errors find %{buildroot}%{python3_sitearch}/fluxacct -name '*.py' -type f ! -perm /111 \ -exec sed -i '1{/^#!/d}' {} \; # Python subcommand permissions - flux requires .py files to be executable # (checked via access(path, R_OK|X_OK) in exec_subcommand_py) # These files are run through `flux python` wrapper, not directly. find %{buildroot}%{_libexecdir}/flux/cmd -name '*.py' -exec chmod 755 {} \; %check # Tests cannot run in mock/koji build environments because: # - t0000-sharness.t (sharness framework self-test) fails due to output # format differences in sub-tests run within isolated environments # - All other tests require a running flux broker instance with the # mf_priority plugin loaded, which isn't available in mock/koji builds : %ldconfig_scriptlets %post %systemd_post flux-accounting.service %preun %systemd_preun flux-accounting.service %postun %systemd_postun_with_restart flux-accounting.service %files %license DISCLAIMER.LLNS %doc README.md NEWS # Python fluxacct package (uses sitearch due to native extensions) %{python3_sitearch}/fluxacct # priority plugin %{_libdir}/flux/job-manager/plugins/mf_priority.so # fluxacct namespace package in flux python dir %{_libdir}/flux/python%{python3_version}/fluxacct # commands + other executables %{_libexecdir}/flux/cmd/flux-account.py %{_libexecdir}/flux/cmd/flux-account-update-fshare %{_libexecdir}/flux/cmd/flux-account-priority-update.py %{_libexecdir}/flux/cmd/flux-account-update-db.py %{_libexecdir}/flux/cmd/flux-account-service.py %{_libexecdir}/flux/cmd/flux-account-fetch-job-records.py %{_libexecdir}/flux/cmd/flux-account-update-usage.py # rc scripts %config(noreplace) %{_sysconfdir}/flux/rc1.d/01-flux-account-priority-update # systemd unit file %{_unitdir}/flux-accounting.service # manpages %{_mandir}/man1/*.1* %changelog * Sun Jan 11 2026 Kushal Gupta - 0.55.0-1 - Initial Fedora package based on upstream v0.55.0