]> git.pld-linux.org Git - packages/pylint.git/blame - pylint.spec
- updated BRs
[packages/pylint.git] / pylint.spec
CommitLineData
bce5cba7
AF
1# TODO:
2# - include examples in package
f7cd7b16
JK
3
4# Conditional build:
9101e20c
JB
5%bcond_with python2 # Python 2.x version
6%bcond_without python3 # Python 3.x version (available as 'py3lint')
7%bcond_without doc # Documentation
8%bcond_with tests # unit tests
f7cd7b16 9
df0ba447
JB
10Summary: Python 2 tool that checks if a module satisfy a coding standard
11Summary(pl.UTF-8): Narzędzie Pythona 2 sprawdzające zgodność modułu ze standardem kodowania
baeb5efa 12Name: pylint
b0e6a315 13Version: 2.4.3
a6607fb4 14Release: 3
e6bafd81 15License: GPL v2+
baeb5efa 16Group: Development/Languages/Python
9101e20c 17#Source0Download: https://pypi.org/simple/pylint/
19641c03 18Source0: https://github.com/PyCQA/pylint/archive/%{name}-%{version}.tar.gz
b0e6a315 19# Source0-md5: 742ac2d6e2528e0d2f52edadd31c837b
ad173d2e 20URL: http://www.pylint.org/
f7cd7b16 21%if %{with python2}
a6607fb4 22BuildRequires: python-astroid >= 2.3.0
9101e20c 23BuildRequires: python-devel >= 1:3.5
a6607fb4 24BuildRequires: python-mccabe
9101e20c 25BuildRequires: python-modules >= 1:3.5
71480d3a 26BuildRequires: python-setuptools >= 7.0
9101e20c 27%if %{with tests}
9101e20c 28BuildRequires: python-isort >= 4.2.5
9101e20c 29BuildRequires: python-mccabe >= 0.6
9101e20c 30%endif
f7cd7b16
JK
31%endif
32%if %{with python3}
a6607fb4 33BuildRequires: python3-astroid >= 1.5.3
9101e20c 34BuildRequires: python3-devel >= 1:3.5
a6607fb4 35BuildRequires: python3-mccabe
9101e20c 36BuildRequires: python3-modules >= 1:3.5
71480d3a 37BuildRequires: python3-setuptools >= 7.0
9101e20c 38%if %{with tests}
9101e20c 39BuildRequires: python3-isort >= 4.2.5
9101e20c 40BuildRequires: python3-mccabe >= 0.6
9101e20c 41%endif
f7cd7b16 42%endif
2ae24f33 43BuildRequires: rpm-pythonprov
9101e20c
JB
44BuildRequires: rpmbuild(macros) >= 1.714
45%if %{with doc}
ad173d2e 46BuildRequires: sphinx-pdg
9101e20c 47%endif
345b7a9d 48Requires: python-pylint = %{version}-%{release}
93850ade 49Suggests: python-devel-src
baeb5efa 50BuildArch: noarch
51BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
52
1ee582a8
ER
53# /etc/pylintrc is deliberately packaged to both packages with same name
54%define _duplicate_files_terminate_build 0
55
baeb5efa 56%description
df0ba447 57Python 2 tool that checks if a module satisfy a coding standard.
baeb5efa 58
65b81fbb 59%description -l pl.UTF-8
df0ba447
JB
60Narzędzie Pythona 2 sprawdzające zgodność modułów napisanych w języku
61Python z regułami tworzenia kodu źródłowego.
c85c0a5a 62
345b7a9d 63%package -n python-pylint
df0ba447
JB
64Summary: Python 2 tool that checks if a module satisfy a coding standard (modules)
65Summary(pl.UTF-8): Narzędzie Pythona sprawdzające zgodność modułu ze standardem kodowania (moduły)
345b7a9d
JK
66Group: Libraries/Python
67
68%description -n python-pylint
df0ba447 69Python 2 tool that checks if a module satisfy a coding standard.
345b7a9d 70
df0ba447 71This package contains only the Python modules used by the tool.
345b7a9d
JK
72
73%description -n python-pylint -l pl.UTF-8
df0ba447
JB
74Narzędzie Pythona 2 sprawdzające zgodność modułów napisanych w języku
75Python z regułami tworzenia kodu źródłowego.
345b7a9d 76
df0ba447 77Ten pakiet zawiera tylko moduły Pythona używane przez to narzędzie.
345b7a9d 78
704b7472 79%package -n py3lint
df0ba447
JB
80Summary: Python 3 tool that checks if a module satisfy a coding standard
81Summary(pl.UTF-8): Narzędzie Pythona 3 sprawdzające zgodność modułu ze standardem kodowania
f7cd7b16 82Group: Development/Languages/Python
345b7a9d 83Requires: python3-pylint = %{version}-%{release}
704b7472 84Obsoletes: pylint-python3 < 1.0.0-2
f7cd7b16 85
704b7472 86%description -n py3lint
df0ba447 87Python 3 tool that checks if a module satisfy a coding standard.
f7cd7b16
JK
88
89Python 3.x version, available via the 'py3lint' command.
90
704b7472 91%description -n py3lint -l pl.UTF-8
df0ba447
JB
92Narzędzie Pythona 3 sprawdzające zgodność modułów napisanych w języku
93Python z regułami tworzenia kodu źródłowego.
f7cd7b16
JK
94
95Wersja dla Pythona 3.x, dostępna przez polecenie 'py3lint'.
96
345b7a9d 97%package -n python3-pylint
df0ba447
JB
98Summary: Python 3 tool that checks if a module satisfy a coding standard (moduły)
99Summary(pl.UTF-8): Narzędzie Pythona 3 sprawdzające zgodność modułu ze standardem kodowania (modules)
345b7a9d
JK
100Group: Libraries/Python
101
102%description -n python3-pylint
df0ba447 103Python 3 tool that checks if a module satisfy a coding standard.
345b7a9d 104
df0ba447 105This package contains only the Python modules used by the tool.
345b7a9d
JK
106
107%description -n python3-pylint -l pl.UTF-8
df0ba447
JB
108Narzędzie Pythona 3 sprawdzające zgodność modułów napisanych w języku
109Python z regułami tworzenia kodu źródłowego.
345b7a9d 110
df0ba447 111Ten pakiet zawiera tylko moduły Pythona używane przez to narzędzie.
345b7a9d 112
9101e20c
JB
113%package doc
114Summary: Documentation for pylint
115Summary(pl.UTF-8): Dokumentacja do pylinta
116Group: Documentation
117
118%description doc
119Documentation for pylint.
120
121%description doc -l pl.UTF-8
122Dokumentacja do pylinta.
123
baeb5efa 124%prep
19641c03 125%setup -q -n pylint-pylint-%{version}
8b70ac82 126
baeb5efa 127%build
f7cd7b16 128%if %{with python2}
15bfcc2d 129%py_build
f7cd7b16
JK
130%endif
131
132%if %{with python3}
15bfcc2d 133%py3_build
f7cd7b16 134%endif
baeb5efa 135
e0de7fee 136%if %{with doc}
e1ce958c 137%{__make} -C doc text \
15bfcc2d 138 PYTHONPATH=$PWD
e0de7fee 139%endif
ad173d2e 140
baeb5efa 141%install
704b7472 142rm -rf $RPM_BUILD_ROOT
4ec6f79e 143install -d $RPM_BUILD_ROOT{%{_sysconfdir},%{_mandir}/man1}
baeb5efa 144
f7cd7b16 145%if %{with python3}
15bfcc2d 146%py3_install
4efaa76d 147
df0ba447
JB
148%{__mv} $RPM_BUILD_ROOT%{_bindir}/epylint $RPM_BUILD_ROOT%{_bindir}/epy3lint
149%{__mv} $RPM_BUILD_ROOT%{_bindir}/pylint $RPM_BUILD_ROOT%{_bindir}/py3lint
df0ba447 150%{__mv} $RPM_BUILD_ROOT%{_bindir}/pyreverse $RPM_BUILD_ROOT%{_bindir}/py3reverse
704b7472
ER
151cp -p man/epylint.1 $RPM_BUILD_ROOT%{_mandir}/man1/epy3lint.1
152cp -p man/pylint.1 $RPM_BUILD_ROOT%{_mandir}/man1/py3lint.1
704b7472 153cp -p man/pyreverse.1 $RPM_BUILD_ROOT%{_mandir}/man1/py3reverse.1
f7cd7b16 154%endif
4efaa76d 155
f7cd7b16 156%if %{with python2}
15bfcc2d 157%py_install
9101e20c 158
7c199dbc 159%py_postclean
704b7472 160cp -p man/*.1 $RPM_BUILD_ROOT%{_mandir}/man1
f7cd7b16
JK
161%endif
162
704b7472 163cp -p examples/pylintrc $RPM_BUILD_ROOT%{_sysconfdir}/pylintrc
baeb5efa 164
165%clean
166rm -rf $RPM_BUILD_ROOT
167
f7cd7b16 168%if %{with python2}
baeb5efa 169%files
170%defattr(644,root,root,755)
ebaa5e6b 171%attr(755,root,root) %{_bindir}/epylint
7c199dbc 172%attr(755,root,root) %{_bindir}/pylint
ebaa5e6b 173%attr(755,root,root) %{_bindir}/pyreverse
7c199dbc 174%attr(755,root,root) %{_bindir}/symilar
b4896848 175%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/pylintrc
6abb03ef
JB
176%{_mandir}/man1/epylint.1*
177%{_mandir}/man1/pylint.1*
178%{_mandir}/man1/pyreverse.1*
179%{_mandir}/man1/symilar.1*
7c199dbc 180
345b7a9d
JK
181%files -n python-pylint
182%defattr(644,root,root,755)
9101e20c 183%doc CONTRIBUTORS.txt ChangeLog README.rst examples/*
345b7a9d
JK
184%{py_sitescriptdir}/pylint
185%{py_sitescriptdir}/pylint-%{version}-py*.egg-info
f7cd7b16
JK
186%endif
187
188%if %{with python3}
704b7472 189%files -n py3lint
f7cd7b16 190%defattr(644,root,root,755)
f7cd7b16
JK
191%attr(755,root,root) %{_bindir}/epy3lint
192%attr(755,root,root) %{_bindir}/py3lint
193%attr(755,root,root) %{_bindir}/py3reverse
704b7472 194%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/pylintrc
f7cd7b16
JK
195%{_mandir}/man1/epy3lint.1*
196%{_mandir}/man1/py3lint.1*
197%{_mandir}/man1/py3reverse.1*
198
345b7a9d
JK
199%files -n python3-pylint
200%defattr(644,root,root,755)
9101e20c 201%doc CONTRIBUTORS.txt ChangeLog README.rst examples/*
345b7a9d
JK
202%{py3_sitescriptdir}/pylint
203%{py3_sitescriptdir}/pylint-%{version}-py*.egg-info
f7cd7b16 204%endif
9101e20c
JB
205
206%if %{with doc}
207%files doc
208%defattr(644,root,root,755)
209%doc doc/_build/text/*
210%endif
This page took 0.537849 seconds and 4 git commands to generate.