[sympy/f14/master] Update to 0.6.7-5.

Jussi Lehtola jussilehtola at fedoraproject.org
Mon Oct 25 08:43:30 UTC 2010


commit 1f9e02c4bef02c06e8919e308e1955e8375682f1
Author: Jussi Lehtola <jussilehtola at fedoraproject.org>
Date:   Mon Oct 25 11:43:21 2010 +0300

    Update to 0.6.7-5.

 sympy-0.6.7-mpf.patch |  108 +++++++++++++++++++++++++++++++++++++++++++++++++
 sympy.spec            |   10 ++++-
 2 files changed, 117 insertions(+), 1 deletions(-)
---
diff --git a/sympy-0.6.7-mpf.patch b/sympy-0.6.7-mpf.patch
new file mode 100644
index 0000000..f4a35bd
--- /dev/null
+++ b/sympy-0.6.7-mpf.patch
@@ -0,0 +1,108 @@
+Index: sympy-0.6.7/sympy/core/numbers.py
+===================================================================
+--- sympy-0.6.7.orig/sympy/core/numbers.py
++++ sympy-0.6.7/sympy/core/numbers.py
+@@ -1040,6 +1040,7 @@ class Zero(Integer):
+ 
+     p = 0
+     q = 1
++    _mpf_ = (0, 0L, 0, 0)
+     is_positive = False
+     is_negative = False
+     is_finite = False
+@@ -1082,6 +1083,7 @@ class One(Integer):
+ 
+     p = 1
+     q = 1
++    _mpf_ = (0, 1L, 0, 1)
+ 
+     is_prime = True
+ 
+@@ -1110,6 +1112,7 @@ class NegativeOne(Integer):
+ 
+     p = -1
+     q = 1
++    _mpf_ = (1, 1L, 0, 1)
+ 
+     __slots__ = []
+ 
+@@ -1150,6 +1153,7 @@ class Half(Rational):
+ 
+     p = 1
+     q = 2
++    _mpf_ = (0, 1L, -1, 1)
+ 
+     __slots__ = []
+ 
+@@ -1163,6 +1167,7 @@ class Infinity(Rational):
+ 
+     p = 1
+     q = 0
++    _mpf_ = mpmath.inf._mpf_
+ 
+     __slots__ = []
+ 
+@@ -1236,6 +1241,7 @@ class NegativeInfinity(Rational):
+ 
+     p = -1
+     q = 0
++    _mpf_ = mpmath.ninf._mpf_
+ 
+     __slots__ = []
+ 
+@@ -1303,6 +1309,7 @@ class NaN(Rational):
+ 
+     p = 0
+     q = 0
++    _mpf_ = mpmath.nan._mpf_
+ 
+     is_commutative = True
+     is_real = None
+@@ -1440,6 +1447,7 @@ class NumberSymbol(Atom):
+ 
+ class Exp1(NumberSymbol):
+ 
++    _mpf_ = mpmath.e._mpf_
+     is_real = True
+     is_positive = True
+     is_negative = False # XXX Forces is_negative/is_nonnegative
+@@ -1469,6 +1477,7 @@ class Exp1(NumberSymbol):
+ 
+ class Pi(NumberSymbol):
+ 
++    _mpf_ = mpmath.pi._mpf_
+     is_real = True
+     is_positive = True
+     is_negative = False
+@@ -1495,6 +1504,7 @@ class Pi(NumberSymbol):
+ 
+ class GoldenRatio(NumberSymbol):
+ 
++    _mpf_ = mpmath.phi._mpf_
+     is_real = True
+     is_positive = True
+     is_negative = False
+@@ -1520,6 +1530,7 @@ class GoldenRatio(NumberSymbol):
+ 
+ class EulerGamma(NumberSymbol):
+ 
++    _mpf_ = mpmath.euler._mpf_
+     is_real = True
+     is_positive = True
+     is_negative = False
+@@ -1543,6 +1554,7 @@ class EulerGamma(NumberSymbol):
+ 
+ class Catalan(NumberSymbol):
+ 
++    _mpf_ = mpmath.catalan._mpf_
+     is_real = True
+     is_positive = True
+     is_negative = False
+@@ -1566,6 +1578,7 @@ class Catalan(NumberSymbol):
+ class ImaginaryUnit(Atom):
+     __metaclass__ = SingletonMeta
+ 
++    _mpc_ = mpmath.j._mpc_
+     is_commutative = True
+     is_imaginary = True
+     is_bounded = True
diff --git a/sympy.spec b/sympy.spec
index 1378d55..925fe47 100644
--- a/sympy.spec
+++ b/sympy.spec
@@ -2,7 +2,7 @@
 
 Name:           sympy
 Version:        0.6.7
-Release:        4%{?dist}
+Release:        5%{?dist}
 Summary:        A Python library for symbolic mathematics
 Group:          Development/Languages
 License:        BSD
@@ -16,6 +16,9 @@ Patch0:         sympy-0.6.7-strip-internal-mpmath.diff
 # Not yet sent upstream:
 Patch1:         sympy-python27.patch
 
+# Add mpf symbols
+Patch2:		sympy-0.6.7-mpf.patch
+
 BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
 
 BuildArch:      noarch
@@ -33,7 +36,9 @@ Python and does not require any external libraries.
 %setup -q
 %patch0 -p1 -b .mpmath
 rm -rf sympy/mpmath doc/src/modules/mpmath
+
 %patch1 -p1
+%patch2 -p1
 
 %build
 python setup.py build
@@ -59,6 +64,9 @@ rm -rf %{buildroot}
 %{_mandir}/man1/isympy.1*
 
 %changelog
+* Mon Aug 30 2010 Jussi Lehtola <jussilehtola at fedoraproject.org> - 0.6.7-5
+- Patch around BZ #564504.
+
 * Sat Jul 31 2010 David Malcolm <dmalcolm at redhat.com> - 0.6.7-4
 - fix a python 2.7 incompatibility
 


More information about the scm-commits mailing list