Пакет python-tools-pep8: Specfile
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 | %def_with python3 %global module_name pep8 Name: python-tools-%{module_name} Version: 1.6.2 Release: alt3 Summary: Python style guide checker Group: Development/Python # License is held in the comments of pep8.py # setup.py claims license is Expat license, which is the same as MIT License: MIT URL: http://pypi.python.org/pypi/%{module_name} Source0: %{name}-%{version}.tar Patch1: pep8-1.6.2-Keep-compability-with-stdlib-tokenize.py-changes.patch BuildArch: noarch BuildRequires: python-devel BuildRequires: python-module-setuptools BuildRequires: python-module-sphinx Requires: python-module-setuptools %description pep8 is a tool to check your Python code against some of the style conventions in PEP 8. It has a plugin architecture, making new checks easy, and its output is parseable, making it easy to jump to an error location in your editor. %if_with python3 %package -n python3-tools-pep8 Summary: Python style guide checker Group: Development/Python BuildRequires: rpm-build-python3 BuildRequires: python3-module-setuptools BuildRequires: python3-module-sphinx Requires: python3-module-setuptools %description -n python3-tools-pep8 pep8 is a tool to check your Python code against some of the style conventions in PEP 8. It has a plugin architecture, making new checks easy, and its output is parseable, making it easy to jump to an error location in your editor. This is a version for Python 3. %endif %prep %setup %patch1 -p1 # Remove #! from pep8.py sed --in-place "s:#!\s*/usr.*::" pep8.py %if_with python3 rm -rf ../python3 cp -a . ../python3 %endif %build %python_build build_sphinx %if_with python3 pushd ../python3 %python3_build popd %endif %install %if_with python3 pushd ../python3 %python3_install mv %{buildroot}%{_bindir}/pep8 %{buildroot}%{_bindir}/python3-pep8 popd %endif %python_install %check %__python pep8.py --testsuite testsuite %__python pep8.py --doctest %if_with python3 pushd ../python3 PYTHONPATH="%{buildroot}%{python3_sitelibdir}:$PYTHONPATH" %{__python3} pep8.py --testsuite testsuite popd %endif %files %doc CHANGES.txt README.rst build/sphinx/html/* %{_bindir}/pep8 %{python_sitelibdir}/%{module_name}.py* %{python_sitelibdir}/%{module_name}-%{version}-*.egg-info %if_with python3 %files -n python3-tools-pep8 %doc README.rst CHANGES.txt build/sphinx/html/* %{_bindir}/python3-pep8 %{python3_sitelibdir}/%{module_name}.py* %{python3_sitelibdir}/%{module_name}-%{version}-*.egg-info/ %{python3_sitelibdir}/__pycache__/%{module_name}* %endif %changelog * Tue Jul 06 2021 Grigory Ustinov <grenka@altlinux.org> 1.6.2-alt3 - Fixed FTBFS. * Thu Jan 31 2019 Stanislav Levin <slev@altlinux.org> 1.6.2-alt2 - Applied patch from upstream for Python 3.6.7+ support. * Fri Apr 08 2016 Ivan Zakharyaschev <imz@altlinux.org> 1.6.2-alt1.1.1 - (NMU) Rebuild with python3-3.5.1-alt3 to get rid of the meaningless __pycache__/ dep (it is meaningless because arbitrary packages package that dir). * Mon Mar 14 2016 Ivan Zakharyaschev <imz@altlinux.org> 1.6.2-alt1.1 - (NMU) rebuild with rpm-build-python3-0.1.9 (for common python3/site-packages/ and auto python3.3-ABI dep when needed) * Mon Feb 16 2015 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 1.6.2-alt1 - Version 1.6.2 * Mon Feb 09 2015 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 1.6.1-alt1 - Version 1.6.1 * Sat Nov 08 2014 Eugeny A. Rostovtsev (REAL) <real at altlinux.org> 1.5.7-alt1 - Version 1.5.7 * Fri Aug 01 2014 Lenar Shakirov <snejok@altlinux.ru> 1.5.6-alt1 - New version (based on Fedora 1.5.6-3.fc21.src) * Thu Oct 20 2011 Vitaly Kuznetsov <vitty@altlinux.ru> 0.6.0-alt2 - Rebuild with Python-2.7 * Wed Sep 28 2011 Vitaly Kuznetsov <vitty@altlinux.ru> 0.6.0-alt1 - Initial based on Fedora spec build |