Hello community,

here is the log from the commit of package python-mpi4py for openSUSE:Factory 
checked in at 2017-06-12 15:28:15
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/python-mpi4py (Old)
 and      /work/SRC/openSUSE:Factory/.python-mpi4py.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "python-mpi4py"

Mon Jun 12 15:28:15 2017 rev:3 rq:498537 version:2.0.0

Changes:
--------
--- /work/SRC/openSUSE:Factory/python-mpi4py/python-mpi4py.changes      
2017-02-03 18:57:50.669771875 +0100
+++ /work/SRC/openSUSE:Factory/.python-mpi4py.new/python-mpi4py.changes 
2017-06-12 15:28:17.363413425 +0200
@@ -1,0 +2,7 @@
+Tue May 23 15:49:20 UTC 2017 - toddrme2...@gmail.com
+
+- Implement single-spec version
+- Fix source URL.
+- Package docs
+
+-------------------------------------------------------------------

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ python-mpi4py.spec ++++++
--- /var/tmp/diff_new_pack.fH0r6j/_old  2017-06-12 15:28:18.311279748 +0200
+++ /var/tmp/diff_new_pack.fH0r6j/_new  2017-06-12 15:28:18.315279184 +0200
@@ -16,23 +16,23 @@
 #
 
 
-%{!?python_sitearch: %global python_sitearch %(%{__python} -c "from 
distutils.sysconfig import get_python_lib; print(get_python_lib(1))")}
-
-%define modname mpi4py
-Name:           python-%{modname}
+%{?!python_module:%define python_module() python-%{**} python3-%{**}}
+Name:           python-mpi4py
 Version:        2.0.0
 Release:        0
 Summary:        MPI for Python
 License:        BSD-2-Clause
 Group:          Development/Libraries/Python
 Url:            https://bitbucket.org/mpi4py/mpi4py
-Source0:        
https://bitbucket.org/%{modname}/%{modname}/downloads/%{modname}-%{version}.tar.gz
+Source:         
https://files.pythonhosted.org/packages/source/m/mpi4py/mpi4py-%{version}.tar.gz
 BuildRequires:  fdupes
+BuildRequires:  python-rpm-macros
+BuildRequires:  %{python_module devel}
+BuildRequires:  %{python_module setuptools}
 BuildRequires:  openmpi-devel
-BuildRequires:  python-devel
 Requires:       openmpi
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
-%py_requires
+%python_subpackages
 
 %description
 This package provides Message Passing Interface support for Python scripting 
in parallel
@@ -62,32 +62,77 @@
 Summary:        Development files for %{name}
 Group:          Development/Libraries/Python
 Requires:       %{name} = %{version}
-%py_requires -d
+Requires:       %{name}-common-devel = %{version}
+Requires:       python-devel
 
 %description devel
+Development libraries and headers needed to build packages using %{name}.
+
+%package -n %{name}-common-devel
+Summary:        Shared development files for %{name}
+Group:          Development/Libraries/Python
+Provides:       %{python_module mpi4py-common-devel = %{version}}
+Requires:       openmpi-devel
+
+%description -n %{name}-common-devel
 Development libraries and headers needed to build packages using %{name}
+for both python2 and python3.
 
+You normally do not need to install this directly, it will be pulled in by
+the python-specific devel package.
+
+%package -n %{name}-doc
+Summary:        Documentation for %{name}
+Group:          Documentation/Other
+Provides:       %{python_module mpi4py-doc = %{version}}
+
+%description -n %{name}-doc
+Documentation files and demos for %{name}.
 
 %prep
-%setup -q -n %{modname}-%{version}
+%setup -q -n mpi4py-%{version}
 
 %build
-env CFLAGS="%{optflags}" python setup.py build
+export CFLAGS="%{optflags}"
+%python_build
 
 %install
-python setup.py install --root=%{buildroot} --prefix=%{_prefix} 
--install-headers=%{_includedir}
-mkdir -p -m 755 %{buildroot}%{_includedir}
-mv %{buildroot}%{python_sitearch}/%{modname}/include/%{modname} 
%{buildroot}/%{_includedir}
-%fdupes -s %{buildroot}
+%python_install
+%python_expand %fdupes %{buildroot}%{$python_sitearch}
+
+# De-duplicate includes and also put them in a more generally-accessible 
location.
+mkdir -p %{buildroot}/%{_includedir}
+%python_expand cp -r %{buildroot}%{$python_sitearch}/mpi4py/include/mpi4py 
%{buildroot}/%{_includedir}/
+%python_expand rm -r %{buildroot}%{$python_sitearch}/mpi4py/include/mpi4py
+%python_expand ln -s %{_includedir}/mpi4py 
%{buildroot}%{$python_sitearch}/mpi4py/include/mpi4py
 
-%files
+%files %{python_files}
+%defattr(-,root,root)
+%doc CHANGES.rst DESCRIPTION.rst README.rst LICENSE.rst
+%{python_sitearch}/mpi4py
+%{python_sitearch}/mpi4py-%{version}-py*.egg-info
+%exclude %{python_sitearch}/mpi4py/include/
+
+%files %{python_files devel}
+%defattr(-,root,root)
+%doc LICENSE.rst
+%dir %{python_sitearch}/mpi4py/include/
+%{python_sitearch}/mpi4py/include/mpi4py
+
+%files -n %{name}-common-devel
 %defattr(-,root,root)
 %doc LICENSE.rst
-%{python_sitearch}/%{modname}
-%{python_sitearch}/%{modname}-%{version}-py%{py_ver}.egg-info
+%dir %{_includedir}/mpi4py/
+%{_includedir}/mpi4py/*.h
+%{_includedir}/mpi4py/*.i
+%{_includedir}/mpi4py/*.pxd
+%{_includedir}/mpi4py/*.pxi
+%{_includedir}/mpi4py/*.pyx
 
-%files devel
+%files -n %{name}-doc
 %defattr(-,root,root)
-%{_includedir}/%{modname}
+%doc LICENSE.rst
+%doc docs/
+%doc demo/
 
 %changelog


Reply via email to