File python-djangorestframework.spec of Package python-djangorestframework
#
# spec file for package python-djangorestframework
#
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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 https://bugs.opensuse.org/
#
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
%define oldpython python
Name: python-djangorestframework
Version: 3.9.0
Release: 0
Summary: A REST Framework for Django
License: BSD-2-Clause
Group: Development/Languages/Python
URL: http://django-rest-framework.org/
Source: https://files.pythonhosted.org/packages/source/d/djangorestframework/djangorestframework-%{version}.tar.gz
BuildRequires: %{python_module Django >= 1.11}
BuildRequires: %{python_module devel}
BuildRequires: fdupes
BuildRequires: python-rpm-macros
Requires: python-Django >= 1.11
Provides: python-django-rest-framework = %{version}
Obsoletes: python-django-rest-framework < %{version}
BuildArch: noarch
%ifpython2
Provides: %{oldpython}-django-rest-framework = %{version}
Obsoletes: %{oldpython}-django-rest-framework < %{version}
%endif
%python_subpackages
%description
Django REST framework is a library for building Web APIs. It is
modular and the architecture can be customized, based on Django's
class based views.
Web APIs built using REST framework are fully self-describing and web
browseable. It also supports a wide range of media types,
authentication and permission policies out of the box.
%prep
%setup -q -n djangorestframework-%{version}
%build
%python_build
%install
%python_install
%python_expand %fdupes %{buildroot}%{$python_sitelib}
%files %{python_files}
%license LICENSE.md
%{python_sitelib}/*
%changelog