New upstream version.
Also: - Update URLs. - Add -numpy patch to fix test failure.
This commit is contained in:
parent
d3b8513d73
commit
a2a62ea27e
1
.gitignore
vendored
1
.gitignore
vendored
@ -2,3 +2,4 @@
|
|||||||
/networkx_tutorial.pdf
|
/networkx_tutorial.pdf
|
||||||
/networkx-documentation.zip
|
/networkx-documentation.zip
|
||||||
/networkx-1.9.1.tar.gz
|
/networkx-1.9.1.tar.gz
|
||||||
|
/networkx-1.10.tar.gz
|
||||||
|
|||||||
20
networkx-numpy.patch
Normal file
20
networkx-numpy.patch
Normal file
@ -0,0 +1,20 @@
|
|||||||
|
With recent versions of numpy, the original expression results in:
|
||||||
|
|
||||||
|
TypeError: Cannot cast ufunc add output from dtype('float64') to dtype('int64')
|
||||||
|
with casting rule 'same_kind'
|
||||||
|
|
||||||
|
This patch solves the issue by not trying to add in place.
|
||||||
|
|
||||||
|
diff -Naur networkx-networkx-1.10.orig/networkx/linalg/algebraicconnectivity.py networkx-networkx-1.10/networkx/linalg/algebraicconnectivity.py
|
||||||
|
--- networkx-networkx-1.10.orig/networkx/linalg/algebraicconnectivity.py 2015-10-30 15:41:35.000000000 -0600
|
||||||
|
+++ networkx-networkx-1.10/networkx/linalg/algebraicconnectivity.py 2015-12-01 09:49:51.568953316 -0700
|
||||||
|
@@ -244,8 +244,7 @@
|
||||||
|
W -= (W.T * X * X.T).T
|
||||||
|
project(W)
|
||||||
|
# Compute the diagonal of P * L * P as a Jacobi preconditioner.
|
||||||
|
- D = L.diagonal()
|
||||||
|
- D += 2. * (asarray(X) * asarray(W)).sum(axis=1)
|
||||||
|
+ D = L.diagonal() + 2. * (asarray(X) * asarray(W)).sum(axis=1)
|
||||||
|
D += (asarray(X) * asarray(X * (W.T * X))).sum(axis=1)
|
||||||
|
D[D < tol * Lnorm] = 1.
|
||||||
|
D = 1. / D
|
||||||
@ -1,23 +1,22 @@
|
|||||||
make importing of drawing and geo subpackages optional
|
make importing of drawing and geo subpackages optional
|
||||||
|
|
||||||
diff -Naur networkx-1.9.orig/networkx/__init__.py networkx-1.9/networkx/__init__.py
|
diff -Naur networkx-networkx-1.10.orig/networkx/__init__.py networkx-networkx-1.10/networkx/__init__.py
|
||||||
--- networkx-1.9.orig/networkx/__init__.py 2014-06-25 12:02:09.000000000 -0600
|
--- networkx-networkx-1.10.orig/networkx/__init__.py 2015-10-30 15:41:35.000000000 -0600
|
||||||
+++ networkx-1.9/networkx/__init__.py 2014-06-30 12:00:00.000000000 -0600
|
+++ networkx-networkx-1.10/networkx/__init__.py 2015-11-24 09:34:20.741823392 -0700
|
||||||
@@ -84,6 +84,8 @@
|
@@ -95,5 +95,8 @@
|
||||||
from networkx.linalg import *
|
from networkx.linalg import *
|
||||||
from networkx.tests.test import run as test
|
from networkx.tests.test import run as test
|
||||||
|
|
||||||
-import networkx.drawing
|
-import networkx.drawing
|
||||||
-from networkx.drawing import *
|
-from networkx.drawing import *
|
||||||
-
|
|
||||||
+try:
|
+try:
|
||||||
+ import networkx.drawing
|
+ import networkx.drawing
|
||||||
+ from networkx.drawing import *
|
+ from networkx.drawing import *
|
||||||
+except ImportError:
|
+except ImportError:
|
||||||
+ pass
|
+ pass
|
||||||
diff -Naur networkx-1.9.orig/networkx/readwrite/__init__.py networkx-1.9/networkx/readwrite/__init__.py
|
diff -Naur networkx-networkx-1.10.orig/networkx/readwrite/__init__.py networkx-networkx-1.10/networkx/readwrite/__init__.py
|
||||||
--- networkx-1.9.orig/networkx/readwrite/__init__.py 2014-06-25 11:50:58.000000000 -0600
|
--- networkx-networkx-1.10.orig/networkx/readwrite/__init__.py 2015-10-30 15:41:35.000000000 -0600
|
||||||
+++ networkx-1.9/networkx/readwrite/__init__.py 2014-06-30 12:00:00.000000000 -0600
|
+++ networkx-networkx-1.10/networkx/readwrite/__init__.py 2015-11-24 09:34:46.539738141 -0700
|
||||||
@@ -14,4 +14,8 @@
|
@@ -14,4 +14,8 @@
|
||||||
from networkx.readwrite.gml import *
|
from networkx.readwrite.gml import *
|
||||||
from networkx.readwrite.graphml import *
|
from networkx.readwrite.graphml import *
|
||||||
|
|||||||
@ -15,18 +15,20 @@
|
|||||||
%global pkgname networkx
|
%global pkgname networkx
|
||||||
|
|
||||||
Name: python-%{pkgname}
|
Name: python-%{pkgname}
|
||||||
Version: 1.9.1
|
Version: 1.10
|
||||||
Release: 5%{?dist}
|
Release: 1%{?dist}
|
||||||
Summary: Creates and Manipulates Graphs and Networks
|
Summary: Creates and Manipulates Graphs and Networks
|
||||||
License: BSD
|
License: BSD
|
||||||
URL: http://networkx.github.io/
|
URL: http://networkx.github.io/
|
||||||
Source0: https://pypi.python.org/packages/source/n/%{pkgname}/%{pkgname}-%{version}.tar.gz
|
Source0: https://github.com/networkx/networkx/archive/%{pkgname}-%{version}.tar.gz
|
||||||
Source1: http://networkx.github.io/documentation/%{pkgname}-%{version}/_downloads/networkx_reference.pdf
|
Source1: https://github.com/networkx/documentation/blob/gh-pages/%{pkgname}-%{version}/_downloads/networkx_reference.pdf
|
||||||
Source2: http://networkx.github.io/documentation/%{pkgname}-%{version}/_downloads/networkx_tutorial.pdf
|
Source2: https://github.com/networkx/documentation/blob/gh-pages/%{pkgname}-%{version}/_downloads/networkx_tutorial.pdf
|
||||||
Source3: http://networkx.github.io/documentation/%{pkgname}-%{version}/_downloads/networkx-documentation.zip
|
Source3: https://github.com/networkx/documentation/blob/gh-pages/%{pkgname}-%{version}/_downloads/networkx-documentation.zip
|
||||||
Patch0: %{pkgname}-optional-modules.patch
|
Patch0: %{pkgname}-optional-modules.patch
|
||||||
Patch1: %{pkgname}-nose1.0.patch
|
Patch1: %{pkgname}-nose1.0.patch
|
||||||
Patch2: %{pkgname}-skip-scipy-0.8-tests.patch
|
Patch2: %{pkgname}-skip-scipy-0.8-tests.patch
|
||||||
|
# Fix failure to add 2 matrices with recent numpy versions
|
||||||
|
Patch3: %{pkgname}-numpy.patch
|
||||||
BuildArch: noarch
|
BuildArch: noarch
|
||||||
|
|
||||||
Requires: %{name}-core = %{version}-%{release}
|
Requires: %{name}-core = %{version}-%{release}
|
||||||
@ -162,7 +164,7 @@ Summary: Documentation for networkx
|
|||||||
%if 0%{?rhel} == 6
|
%if 0%{?rhel} == 6
|
||||||
BuildRequires: python-sphinx10
|
BuildRequires: python-sphinx10
|
||||||
%else
|
%else
|
||||||
BuildRequires: python-sphinx
|
BuildRequires: python2-sphinx
|
||||||
BuildRequires: python-sphinx_rtd_theme
|
BuildRequires: python-sphinx_rtd_theme
|
||||||
BuildRequires: python-numpydoc
|
BuildRequires: python-numpydoc
|
||||||
%endif
|
%endif
|
||||||
@ -177,12 +179,13 @@ Documentation for networkx
|
|||||||
|
|
||||||
|
|
||||||
%prep
|
%prep
|
||||||
%setup -q -n %{pkgname}-%{version}
|
%setup -q -n %{pkgname}-%{pkgname}-%{version}
|
||||||
%patch0 -p1
|
%patch0 -p1
|
||||||
%if 0%{?rhel} == 6
|
%if 0%{?rhel} == 6
|
||||||
%patch1 -p1
|
%patch1 -p1
|
||||||
%patch2 -p1
|
%patch2 -p1
|
||||||
%endif
|
%endif
|
||||||
|
%patch3 -p1
|
||||||
|
|
||||||
# Fix permissions
|
# Fix permissions
|
||||||
find examples -type f -perm /0111 | xargs chmod a-x
|
find examples -type f -perm /0111 | xargs chmod a-x
|
||||||
@ -195,7 +198,7 @@ python2 setup.py build
|
|||||||
%if 0%{?rhel} == 6
|
%if 0%{?rhel} == 6
|
||||||
PYTHONPATH=$PWD/build/lib make SPHINXBUILD=sphinx-1.0-build -C doc html
|
PYTHONPATH=$PWD/build/lib make SPHINXBUILD=sphinx-1.0-build -C doc html
|
||||||
%else
|
%else
|
||||||
PYTHONPATH=$PWD/build/lib make -C doc html
|
PYTHONPATH=$PWD/build/lib make SPHINXBUILD=sphinx-build-2 -C doc html
|
||||||
%endif
|
%endif
|
||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
@ -247,10 +250,10 @@ rm -f /tmp/tmp??????
|
|||||||
%check
|
%check
|
||||||
mkdir site-packages
|
mkdir site-packages
|
||||||
mv networkx site-packages
|
mv networkx site-packages
|
||||||
PYTHONPATH=`pwd`/site-packages python -c "import networkx; networkx.test()"
|
PYTHONPATH=$PWD/site-packages python -c "import networkx; networkx.test()"
|
||||||
|
|
||||||
%files
|
%files
|
||||||
%doc README.txt
|
%doc README.rst
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
|
|
||||||
%files core
|
%files core
|
||||||
@ -271,7 +274,7 @@ PYTHONPATH=`pwd`/site-packages python -c "import networkx; networkx.test()"
|
|||||||
|
|
||||||
%if 0%{?with_python3}
|
%if 0%{?with_python3}
|
||||||
%files -n python3-networkx
|
%files -n python3-networkx
|
||||||
%doc README.txt
|
%doc README.rst
|
||||||
%license LICENSE.txt
|
%license LICENSE.txt
|
||||||
|
|
||||||
%files -n python3-networkx-core
|
%files -n python3-networkx-core
|
||||||
@ -299,6 +302,11 @@ PYTHONPATH=`pwd`/site-packages python -c "import networkx; networkx.test()"
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Tue Dec 1 2015 Jerry James <loganjerry@gmail.com> - 1.10-1
|
||||||
|
- New upstream version
|
||||||
|
- Update URLs
|
||||||
|
- Add -numpy patch to fix test failure
|
||||||
|
|
||||||
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-5
|
* Tue Nov 10 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.9.1-5
|
||||||
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
|
- Rebuilt for https://fedoraproject.org/wiki/Changes/python3.5
|
||||||
|
|
||||||
|
|||||||
8
sources
8
sources
@ -1,4 +1,4 @@
|
|||||||
a2d9ee8427c5636426f319968e0af9f2 networkx-1.9.1.tar.gz
|
abce95ecda7b990cda39391f1d00bc43 networkx-1.10.tar.gz
|
||||||
07c5c31b522c8195fa5123de45c84311 networkx_reference.pdf
|
1bc817b2b73c812f48619a284ed067d8 networkx_reference.pdf
|
||||||
fc244b2a697d87788d9bc51a5997a9af networkx_tutorial.pdf
|
9f3a3dc0fe5c32b23a47906a22a49bba networkx_tutorial.pdf
|
||||||
83a7702ccc4031cc43f236a58d43ca67 networkx-documentation.zip
|
eab78caf7dfcb7833f5e45457c0f323a networkx-documentation.zip
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user