python-pyflakes/python-pyflakes.spec

94 lines
2.8 KiB
RPMSpec

%define pkgname %(echo %name | cut -d- -f2- | tr - _)
Name: python-pyflakes
Version: 3.0.1
Release: 2mamba
Summary: Passive checker of Python programs
Group: System/Libraries/Python
Vendor: openmamba
Distribution: openmamba
Packager: Silvan Calarco <silvan.calarco@mambasoft.it>
URL: https://github.com/PyCQA/pyflakes
Source: https://pypi.debian.net/pyflakes/pyflakes-%{version}.tar.gz
License: MIT
## AUTOBUILDREQ-BEGIN
BuildRequires: libpython3-devel
BuildRequires: python3.7dist(setuptools)
## AUTOBUILDREQ-END
%description
PyFlakes a Lint-like tool for Python, like PyChecker.
It is focused on identifying common errors quickly without executing Python code.
Its primary advantage over PyChecker is that it is fast.
%if 0%{?with_pyver}
%if "%{?with_pyver}" == "3"
%define py_requires_append \
Provides: pyflakes \
Obsoletes: pyflakes < 3.0.1-2mamba
%endif
%pyver_package
%endif
%prep
%setup -q -n %{pkgname}-%{version}
%build
%{__python} setup.py build
%install
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%{__python} setup.py install \
-O1 --skip-build \
--root="%{buildroot}" \
--install-headers=%{_includedir}/python \
--install-lib=%{python_sitearch} \
--record=%{name}.filelist
sed -i "\,\.egg-info/,d;s,.*/man/.*,&.gz," %{name}.filelist
%if "%{?with_pyver}" != "3"
# Rename any conflicting file outside of python site packages tree
for f in %{_bindir}/pyflakes; do
mv %{buildroot}${f}{,-%{?pyappend}}
done
sed -i "\,%{_bindir},d" %{name}.filelist
%endif
%clean
[ "%{buildroot}" != / ] && rm -rf "%{buildroot}"
%files %{?pyappend} -f %{name}.filelist
%defattr(-,root,root)
%{_bindir}/pyflakes*
%dir %{python_sitearch}/pyflakes-%{version}-py*.egg-info
%{python_sitearch}/pyflakes-%{version}-py*.egg-info/*
%changelog
* Fri Apr 07 2023 Sdk Build System <sdk@mambasoft.it> 3.0.1-2mamba
- rebuilt with python 3.10
* Sat Nov 26 2022 Automatic Build System <autodist@mambasoft.it> 3.0.1-1mamba
- automatic version update by autodist
* Fri Nov 25 2022 Automatic Build System <autodist@mambasoft.it> 3.0.0-1mamba
- automatic version update by autodist
* Thu Aug 04 2022 Automatic Build System <autodist@mambasoft.it> 2.5.0-1mamba
- automatic version update by autodist
* Fri Oct 22 2021 Silvan Calarco <silvan.calarco@mambasoft.it> 2.4.0-1mamba
- update to 2.4.0
* Mon Mar 29 2021 Automatic Build System <autodist@mambasoft.it> 2.3.1-1mamba
- automatic version update by autodist
* Mon Feb 22 2021 Automatic Build System <autodist@mambasoft.it> 2.2.0-1mamba
- automatic version update by autodist
* Wed Oct 07 2015 Silvan Calarco <silvan.calarco@mambasoft.it> 1.0.0-1mamba
- update to 1.0.0
* Wed Sep 29 2010 Stefano Cotta Ramusino <stefano.cotta@openmamba.org> 0.4.0-1mamba
- package created by autospec