forked from pool/python-pymongo
Accepting request 491272 from home:TheBlackCat:branches:devel:languages:python
- Update to Version3.4 - Implement single-spec version - Fix source URL. OBS-URL: https://build.opensuse.org/request/show/491272 OBS-URL: https://build.opensuse.org/package/show/devel:languages:python/python-pymongo?expand=0&rev=47
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package python-pymongo
|
||||
#
|
||||
# Copyright (c) 2016 SUSE LINUX GmbH, Nuernberg, Germany.
|
||||
# Copyright (c) 2017 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
|
||||
@@ -16,24 +16,26 @@
|
||||
#
|
||||
|
||||
|
||||
%bcond_without tests
|
||||
|
||||
%{?!python_module:%define python_module() python-%{**} python3-%{**}}
|
||||
Name: python-pymongo
|
||||
Version: 3.1.1
|
||||
Version: 3.4.0
|
||||
Release: 0
|
||||
Url: http://github.com/mongodb/mongo-python-driver
|
||||
Summary: Python driver for MongoDB
|
||||
License: Apache-2.0
|
||||
Group: Development/Languages/Python
|
||||
Source: http://pypi.python.org/packages/source/p/pymongo/pymongo-%{version}.tar.gz
|
||||
Source: https://files.pythonhosted.org/packages/source/p/pymongo/pymongo-%{version}.tar.gz
|
||||
# PATCH-FIX-UPSTREAm -- tests_should_pass_without_MongoDB_running.patch -- https://jira.mongodb.org/browse/PYTHON-1216
|
||||
Patch0: tests_should_pass_without_MongoDB_running.patch
|
||||
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
||||
BuildRequires: python-devel
|
||||
BuildRequires: python-setuptools
|
||||
BuildRequires: python-unittest2
|
||||
%if 0%{?suse_version}
|
||||
BuildRequires: fdupes
|
||||
BuildRequires: python-rpm-macros
|
||||
BuildRequires: %{python_module devel}
|
||||
BuildRequires: %{python_module setuptools}
|
||||
Suggests: mongodb
|
||||
%endif
|
||||
%if 0%{?suse_version} && 0%{?suse_version} <= 1110
|
||||
%{!?python_sitearch: %global python_sitearch %(python -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")}
|
||||
%endif
|
||||
%python_subpackages
|
||||
|
||||
%description
|
||||
The PyMongo distribution contains tools for interacting with MongoDB
|
||||
@@ -44,17 +46,27 @@ implementation on top of pymongo.
|
||||
|
||||
%prep
|
||||
%setup -q -n pymongo-%{version}
|
||||
%patch0 -p1
|
||||
|
||||
%build
|
||||
CFLAGS="%{optflags}" python setup.py build
|
||||
export CFLAGS="%{optflags}"
|
||||
%python_build
|
||||
|
||||
%install
|
||||
python setup.py install --prefix=%{_prefix} --root=%{buildroot}
|
||||
%python_install
|
||||
|
||||
%ifarch %{ix86} x86_64 %{arm} aarch64 ppc64le
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitearch}
|
||||
%else
|
||||
%python_expand %fdupes %{buildroot}%{$python_sitelib}
|
||||
%endif
|
||||
|
||||
%if %{with tests}
|
||||
%check
|
||||
python setup.py test
|
||||
%python_exec setup.py test
|
||||
%endif
|
||||
|
||||
%files
|
||||
%files %{python_files}
|
||||
%defattr(-,root,root,-)
|
||||
%doc LICENSE README.rst
|
||||
%ifarch %{ix86} x86_64 %{arm} aarch64 ppc64le
|
||||
|
Reference in New Issue
Block a user