2013-11-28 15:49:38 +01:00
|
|
|
#
|
|
|
|
# spec file for package python-astroid
|
|
|
|
#
|
2017-03-15 16:32:03 +01:00
|
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
2013-11-28 15:49:38 +01:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
2017-03-15 16:32:03 +01:00
|
|
|
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
|
|
|
%define oldpython python
|
2013-11-28 15:49:38 +01:00
|
|
|
Name: python-astroid
|
2017-03-21 17:03:25 +01:00
|
|
|
Version: 1.4.9.git.1489768950.31f21cd
|
2013-11-28 15:49:38 +01:00
|
|
|
Release: 0
|
2013-11-28 15:55:58 +01:00
|
|
|
Summary: Rebuild a new abstract syntax tree from Python's ast
|
2013-11-28 15:49:38 +01:00
|
|
|
License: LGPL-2.1+
|
|
|
|
Group: Development/Libraries/Python
|
2017-03-15 16:32:03 +01:00
|
|
|
Url: https://github.com/pycqa/astroid
|
2017-03-21 17:03:25 +01:00
|
|
|
# replaced for github pre-release
|
|
|
|
#Source: https://files.pythonhosted.org/packages/source/a/astroid/astroid-%{version}.tar.gz
|
|
|
|
Source: astroid-%{version}.tar.gz
|
2017-03-15 16:32:03 +01:00
|
|
|
Source1: pytest.ini
|
|
|
|
BuildRequires: %{python_module lazy-object-proxy}
|
|
|
|
BuildRequires: %{python_module pytest}
|
|
|
|
BuildRequires: %{python_module setuptools}
|
|
|
|
BuildRequires: %{python_module six}
|
|
|
|
BuildRequires: %{python_module wrapt}
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: python-rpm-macros
|
|
|
|
BuildRequires: python2-backports.functools_lru_cache
|
|
|
|
BuildRequires: python2-enum34
|
|
|
|
BuildRequires: python2-singledispatch
|
|
|
|
Requires: python-lazy-object-proxy
|
2014-11-21 10:01:07 +01:00
|
|
|
Requires: python-six
|
2016-02-22 15:48:17 +01:00
|
|
|
Requires: python-wrapt
|
2017-03-15 16:32:03 +01:00
|
|
|
%ifpython2
|
|
|
|
Requires: python-backports.functools_lru_cache
|
|
|
|
Requires: python-enum34
|
|
|
|
Requires: python-singledispatch
|
2013-11-28 15:49:38 +01:00
|
|
|
%endif
|
2017-03-15 16:32:03 +01:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
BuildArch: noarch
|
|
|
|
%python_subpackages
|
2013-11-28 15:49:38 +01:00
|
|
|
|
|
|
|
%description
|
|
|
|
The aim of this module is to provide a common base representation of
|
|
|
|
python source code for projects such as pychecker, pyreverse,
|
|
|
|
pylint... Well, actually the development of this library is
|
|
|
|
essentially governed by pylint's needs. It used to be called
|
|
|
|
logilab-astng.
|
|
|
|
|
|
|
|
It provides a compatible representation which comes from the _ast
|
|
|
|
module. It rebuilds the tree generated by the builtin _ast module by
|
|
|
|
recursively walking down the AST and building an extended ast. The new
|
|
|
|
node classes have additional methods and attributes for different
|
|
|
|
usages. They include some support for static inference and local name
|
|
|
|
scopes. Furthermore, astroid builds partial trees by inspecting living
|
|
|
|
objects.
|
|
|
|
|
|
|
|
%prep
|
2017-03-15 16:32:03 +01:00
|
|
|
%setup -q -n astroid-%{version}
|
2013-11-28 15:49:38 +01:00
|
|
|
|
|
|
|
%build
|
2017-03-15 16:32:03 +01:00
|
|
|
%python_build
|
2013-11-28 15:49:38 +01:00
|
|
|
|
|
|
|
%install
|
2017-03-15 16:32:03 +01:00
|
|
|
%python_install
|
|
|
|
%fdupes %{buildroot}%{_prefix}
|
|
|
|
|
|
|
|
%check
|
|
|
|
cp %{S:1} .
|
|
|
|
%python_exec -m pytest -s
|
2013-11-28 15:49:38 +01:00
|
|
|
|
2017-03-15 16:32:03 +01:00
|
|
|
%files %{python_files}
|
2013-11-28 15:49:38 +01:00
|
|
|
%defattr(-,root,root,-)
|
2016-01-13 11:21:03 +01:00
|
|
|
%doc COPYING COPYING.LESSER ChangeLog README.rst
|
2013-11-28 15:49:38 +01:00
|
|
|
%{python_sitelib}/astroid/
|
2017-03-15 16:32:03 +01:00
|
|
|
#%{python_sitelib}/astroid-%{version}-py*.egg-info
|
|
|
|
%{python_sitelib}/astroid-*.egg-info
|
2013-11-28 15:49:38 +01:00
|
|
|
|
|
|
|
%changelog
|