%global pyver 3.15 %global python python%{pyver} %global puresitedir %{_prefix}/lib/python%{pyver}/site-packages Name: python%{pyver}-charset-normalizer Version: 3.4.9 Release: 1%{?dist} Summary: Universal charset detector License: MIT URL: https://github.com/Ousret/charset_normalizer Source0: https://files.pythonhosted.org/packages/source/c/charset-normalizer/charset_normalizer-%{version}.tar.gz BuildArch: noarch BuildRequires: python%{pyver} BuildRequires: python%{pyver}-libs BuildRequires: python%{pyver}-setuptools BuildRequires: python%{pyver}-wheel BuildRequires: python%{pyver}-pip BuildRequires: python%{pyver}-installer Requires: python%{pyver}-libs %description A library for encoding detection, alternative to chardet. %prep %autosetup -n charset_normalizer-%{version} # Disable custom mypyc backend (we don't need compiled speedups for bootstrap) sed -i 's/^build-backend = "backend"/build-backend = "setuptools.build_meta"/' pyproject.toml sed -i '/^backend-path/d' pyproject.toml %build %{python} -m pip wheel --no-deps --no-build-isolation -w dist . %install %{python} -m installer --destdir=%{buildroot} dist/*.whl # May install a normalizer binary rm -f %{buildroot}%{_bindir}/normalizer %files %license LICENSE %{puresitedir}/charset_normalizer/ %{puresitedir}/charset_normalizer-%{version}.dist-info/ %changelog * Thu Jul 09 2026 Yonghang Wang - 3.4.9-1%{?dist} - Build for al2023