%global pyver 3.15 %global python python%{pyver} %global puresitedir %{_prefix}/lib/python%{pyver}/site-packages %global srcname build %global version 1.5.0 Name: python%{pyver}-%{srcname} Version: %{version} Release: 1%{?dist}%{?_trivial}%{?_buildid} Summary: A simple, correct Python build frontend License: MIT URL: https://github.com/pypa/build Source0: https://files.pythonhosted.org/packages/source/b/%{srcname}/%{srcname}-%{version}.tar.gz BuildArch: noarch BuildRequires: python%{pyver} BuildRequires: python%{pyver}-libs BuildRequires: python%{pyver}-setuptools BuildRequires: python%{pyver}-wheel BuildRequires: python%{pyver}-installer BuildRequires: python%{pyver}-flit-core Requires: python%{pyver}-libs Requires: python%{pyver}-packaging Requires: python%{pyver}-tomli %description A simple, correct PEP 517 build frontend. %prep %autosetup -n %{srcname}-%{version} %build %{python} -m flit_core.wheel %install %{python} -m installer --destdir=%{buildroot} dist/*.whl # Fix shebangs and remove unversioned commands find %{buildroot}%{_bindir} -type f -exec \ sed -i '1s|^#!.*python.*$|#!/usr/bin/python%{pyver}|' {} \; 2>/dev/null || true %check PYTHONPATH=%{buildroot}%{puresitedir} %{python} -c "import build; print(build.__version__)" %files %license LICENSE %{_bindir}/pyproject-build %{puresitedir}/build/ %{puresitedir}/build-%{version}.dist-info/ %changelog * Wed Jul 08 2026 Yonghang Wang - %{version}-1%{?dist}%{?_trivial}%{?_buildid} - Build for al2023