]> git.pld-linux.org Git - packages/python-astroid.git/blame - python-astroid.spec
- release 2
[packages/python-astroid.git] / python-astroid.spec
CommitLineData
5b74327b 1# NOTE: 1.6.6 is the last version with python 2.7 support; for newer, python3-only releases see python3-astroid.spec
86ae2efd 2#
797e8d54 3# Conditional build:
5b74327b
JB
4%bcond_with tests # unit tests (too many failures)
5%bcond_without python2 # Python 2.x module
6%bcond_with python3 # Python 3.x module (newer version is built from python3-astroid.spec)
797e8d54 7
935ded5d 8%define module astroid
424da304
JB
9Summary: An abstract syntax tree for Python 2 with inference support
10Summary(pl.UTF-8): Abstrakcyjnego drzewa składniowe dla Pythona 2 z obsługą wywodu
935ded5d 11Name: python-%{module}
349824db 12# DO NOT UPGRADE TO 2.x, SEE NOTE ABOVE
94f890e5 13Version: 1.6.6
c6ab7054 14Release: 2
5b74327b 15Epoch: 1
f33b8242 16License: LGPL v2.1+
f3ce12d1 17Group: Development/Languages/Python
c8eef9e6 18#Source0Download: https://pypi.org/simple/astroid/
00f52389 19Source0: https://files.pythonhosted.org/packages/source/a/astroid/astroid-%{version}.tar.gz
94f890e5 20# Source0-md5: ce625aa26b8e93b4d6802401e0cf672b
965510b3 21URL: https://github.com/PyCQA/astroid
797e8d54 22%if %{with python2}
b42224b7
JB
23BuildRequires: python-devel >= 1:2.7
24BuildRequires: python-modules >= 1:2.7
5b74327b 25BuildRequires: python-setuptools >= 17.1
c8eef9e6 26%if %{with tests}
5b74327b
JB
27BuildRequires: python-backports.functools_lru_cache
28BuildRequires: python-enum34 >= 1.1.3
29BuildRequires: python-lazy-object-proxy
c8eef9e6 30BuildRequires: python-pytest
5b74327b
JB
31BuildRequires: python-pytest-runner
32BuildRequires: python-singledispatch
33BuildRequires: python-six
34BuildRequires: python-wrapt
c8eef9e6 35%endif
797e8d54
JK
36%endif
37%if %{with python3}
5b74327b 38BuildRequires: python3-devel >= 1:3.4
c8eef9e6 39BuildRequires: python3-modules >= 1:3.5
5b74327b 40BuildRequires: python3-setuptools >= 17.1
c8eef9e6 41%if %{with tests}
5b74327b 42BuildRequires: python3-lazy-object-proxy
c8eef9e6 43BuildRequires: python3-pytest
5b74327b
JB
44BuildRequires: python3-pytest-runner
45BuildRequires: python3-six
c8eef9e6 46BuildRequires: python3-wrapt >= 1.11
797e8d54 47%endif
c8eef9e6
JB
48%endif
49BuildRequires: rpm-pythonprov
50BuildRequires: rpmbuild(macros) >= 1.714
b42224b7 51Requires: python-modules >= 1:2.7
ea88bfee 52Obsoletes: python-logilab-astng
f3ce12d1
KK
53BuildArch: noarch
54BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
55
56%description
8dd567ae 57The aim of this module is to provide a common base representation of
86ae2efd 58Python source code for projects such as pychecker, pyreverse,
8dd567ae
AF
59pylint... Well, actually the development of this library is
60essentially governed by pylint's needs. It used to be called
61logilab-astng.
f3ce12d1 62
9522705c
JR
63%description -l pl.UTF-8
64Celem tego modułu jest dostarczenie wspólnej bazowej reprezentacji
65kodu źródłowego Pythona dla projektów takich jak pychecker, pyreverse,
66pylint... Właściwie tworzenie tej biblioteki jest istotnie kierowane
86ae2efd 67potrzebami pylinta. Dawniej nazywała się logilab-astng.
8504e807 68
797e8d54 69%package -n python3-%{module}
424da304
JB
70Summary: An abstract syntax tree for Python 3 with inference support
71Summary(pl.UTF-8): Abstrakcyjnego drzewa składniowe dla Pythona 3 z obsługą wywodu
797e8d54 72Group: Development/Languages/Python
5b74327b 73Requires: python3-modules >= 1:3.4
ea88bfee 74Obsoletes: python3-logilab-astng
797e8d54
JK
75
76%description -n python3-%{module}
8dd567ae 77The aim of this module is to provide a common base representation of
86ae2efd 78Python source code for projects such as pychecker, pyreverse,
8dd567ae
AF
79pylint... Well, actually the development of this library is
80essentially governed by pylint's needs. It used to be called
81logilab-astng.
797e8d54
JK
82
83%description -n python3-%{module} -l pl.UTF-8
84Celem tego modułu jest dostarczenie wspólnej bazowej reprezentacji
85kodu źródłowego Pythona dla projektów takich jak pychecker, pyreverse,
86pylint... Właściwie tworzenie tej biblioteki jest istotnie kierowane
86ae2efd 87potrzebami pylinta. Dawniej nazywała się logilab-astng.
797e8d54 88
f3ce12d1 89%prep
abbaad7a 90%setup -q -n %{module}-%{version}
60fa4681 91
c8eef9e6 92# non-deterministic (skipped if numpy not installed; unittest_brain_numpy_core_multiarray.py fails with numpy 1.16.5
5b74327b 93#%{__rm} astroid/tests/unittest_brain_numpy_*
c8eef9e6 94# test_knownValues_get_builtin_module_part fails
5b74327b 95#%{__rm} astroid/tests/unittest_modutils.py
f3ce12d1
KK
96
97%build
797e8d54 98%if %{with python2}
08f50e0d 99%py_build
c8eef9e6
JB
100
101%if %{with tests}
102%{__python} -m pytest astroid/tests
103%endif
797e8d54 104%endif
c8eef9e6 105
797e8d54 106%if %{with python3}
c8eef9e6
JB
107%py3_build
108
109%if %{with tests}
110%{__python3} -m pytest astroid/tests
111%endif
797e8d54 112%endif
f3ce12d1
KK
113
114%install
115rm -rf $RPM_BUILD_ROOT
116
797e8d54 117%if %{with python3}
cd33eed2 118%py3_install
797e8d54
JK
119%endif
120
121%if %{with python2}
08f50e0d 122%py_install
f3ce12d1 123
5a062cc9 124%py_postclean
797e8d54 125%endif
f3ce12d1 126
f3ce12d1
KK
127%clean
128rm -rf $RPM_BUILD_ROOT
129
8f194190 130%if %{with python2}
f3ce12d1
KK
131%files
132%defattr(644,root,root,755)
00f52389 133%doc ChangeLog README.rst
935ded5d
AF
134%{py_sitescriptdir}/astroid
135%{py_sitescriptdir}/astroid-%{version}-py*.egg-info
8f194190 136%endif
797e8d54 137
8f194190 138%if %{with python3}
797e8d54
JK
139%files -n python3-%{module}
140%defattr(644,root,root,755)
00f52389 141%doc ChangeLog README.rst
935ded5d
AF
142%{py3_sitescriptdir}/astroid
143%{py3_sitescriptdir}/astroid-%{version}-py*.egg-info
8f194190 144%endif
This page took 0.087463 seconds and 4 git commands to generate.