1 | %{!?python_sitearch: %define python_sitearch %(%{__python} -c "from distutils.sysconfig import get_python_lib; print get_python_lib(1)")} |
---|
2 | # eval to 2.3 if python isn't yet present, workaround for no python in fc4 minimal buildroot |
---|
3 | %{!?python_version: %define python_version %(%{__python} -c 'import sys; print sys.version.split(" ")[0]' || echo "2.3")} |
---|
4 | |
---|
5 | Name: numpy |
---|
6 | Summary: A fast multidimensional array facility for Python |
---|
7 | Version: 1.4.1 |
---|
8 | Release: 8%{?_dist_release} |
---|
9 | |
---|
10 | Group: Development/Languages |
---|
11 | License: BSD |
---|
12 | URL: http://numeric.scipy.org/ |
---|
13 | |
---|
14 | Source0: http://downloads.sourceforge.net/numpy/%{name}-%{version}.tar.gz |
---|
15 | Patch0: numpy-1.0.1-f2py.patch |
---|
16 | Patch1: numpy_doublefree.patch |
---|
17 | |
---|
18 | # PyOS_ascii_strtod is deprecated in python 2.7, and the deprecation warning |
---|
19 | # outside of the GIL causes python to segfault (rhbz#617384) |
---|
20 | # Patch is a combination of upstream changeset 7926 followed by 8387 |
---|
21 | Patch2: numpy-1.4.1-remove-PyOS_ascii_strtod.patch |
---|
22 | |
---|
23 | ## patches from debian |
---|
24 | Patch3: changeset_r8510.diff |
---|
25 | Patch4: changeset_r8511.diff |
---|
26 | |
---|
27 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
28 | |
---|
29 | #BuildRequires: python-devel lapack-devel python-setuptools gcc-gfortran atlas-devel python-nose |
---|
30 | BuildRequires: python-devel lapack-devel python-setuptools gcc-gfortran python-nose |
---|
31 | Requires: python-nose |
---|
32 | |
---|
33 | %description |
---|
34 | NumPy is a general-purpose array-processing package designed to |
---|
35 | efficiently manipulate large multi-dimensional arrays of arbitrary |
---|
36 | records without sacrificing too much speed for small multi-dimensional |
---|
37 | arrays. NumPy is built on the Numeric code base and adds features |
---|
38 | introduced by numarray as well as an extended C-API and the ability to |
---|
39 | create arrays of arbitrary type. |
---|
40 | |
---|
41 | There are also basic facilities for discrete fourier transform, |
---|
42 | basic linear algebra and random number generation. Also included in |
---|
43 | this package is a version of f2py that works properly with NumPy. |
---|
44 | |
---|
45 | %package f2py |
---|
46 | Summary: f2py for numpy |
---|
47 | Group: Development/Libraries |
---|
48 | Requires: %{name} = %{version}-%{release} |
---|
49 | Requires: python-devel |
---|
50 | Provides: f2py |
---|
51 | Obsoletes: f2py <= 2.45.241_1927 |
---|
52 | |
---|
53 | %description f2py |
---|
54 | This package includes a version of f2py that works properly with NumPy. |
---|
55 | |
---|
56 | %prep |
---|
57 | %setup -q -n %{name}-%{version} |
---|
58 | %patch0 -p1 -b .f2py |
---|
59 | %patch1 -p0 |
---|
60 | %patch2 -p1 -b .remove-PyOS_ascii_strtod |
---|
61 | %patch3 -p1 -b .r8510 |
---|
62 | %patch4 -p1 -b .r8511 |
---|
63 | |
---|
64 | %build |
---|
65 | env FFTW=%{_libdir} BLAS=%{_libdir} \ |
---|
66 | LAPACK=%{_libdir} CFLAGS="$RPM_OPT_FLAGS" \ |
---|
67 | %{__python} setup.py build --fcompiler=gnu95 |
---|
68 | |
---|
69 | %install |
---|
70 | rm -rf $RPM_BUILD_ROOT |
---|
71 | #%{__python} setup.py install -O1 --skip-build --root $RPM_BUILD_ROOT |
---|
72 | # skip-build currently broken, this works around it for now |
---|
73 | env ATLAS=%{_libdir} FFTW=%{_libdir} BLAS=%{_libdir} \ |
---|
74 | LAPACK=%{_libdir} CFLAGS="$RPM_OPT_FLAGS" \ |
---|
75 | %{__python} setup.py install --root $RPM_BUILD_ROOT |
---|
76 | rm -rf docs-f2py ; mv $RPM_BUILD_ROOT%{python_sitearch}/%{name}/f2py/docs docs-f2py |
---|
77 | mv -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/f2py/f2py.1 f2py.1 |
---|
78 | rm -rf doc ; mv -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/doc . |
---|
79 | install -D -p -m 0644 f2py.1 $RPM_BUILD_ROOT%{_mandir}/man1/f2py.1 |
---|
80 | pushd $RPM_BUILD_ROOT%{_bindir} &> /dev/null |
---|
81 | # symlink for anyone who was using f2py.numpy |
---|
82 | ln -s f2py f2py.numpy |
---|
83 | popd &> /dev/null |
---|
84 | |
---|
85 | #symlink for includes, BZ 185079 |
---|
86 | mkdir -p $RPM_BUILD_ROOT/usr/include |
---|
87 | ln -s %{python_sitearch}/%{name}/core/include/numpy/ $RPM_BUILD_ROOT/usr/include/numpy |
---|
88 | |
---|
89 | # Remove doc files. They should in in %doc |
---|
90 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/COMPATIBILITY |
---|
91 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/DEV_README.txt |
---|
92 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/INSTALL.txt |
---|
93 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/LICENSE.txt |
---|
94 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/README.txt |
---|
95 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/THANKS.txt |
---|
96 | rm -f $RPM_BUILD_ROOT%{python_sitearch}/%{name}/site.cfg.example |
---|
97 | |
---|
98 | %check |
---|
99 | pushd doc &> /dev/null |
---|
100 | PYTHONPATH="%{buildroot}%{python_sitearch}" %{__python} -c "import pkg_resources, numpy ; numpy.test()" \ |
---|
101 | %ifarch s390 s390x |
---|
102 | || : |
---|
103 | %endif |
---|
104 | # don't remove this comment |
---|
105 | popd &> /dev/null |
---|
106 | |
---|
107 | %clean |
---|
108 | rm -rf $RPM_BUILD_ROOT |
---|
109 | |
---|
110 | %files |
---|
111 | %defattr(-,root,root,-) |
---|
112 | %doc docs-f2py doc/* LICENSE.txt README.txt THANKS.txt DEV_README.txt COMPATIBILITY site.cfg.example |
---|
113 | %dir %{python_sitearch}/%{name} |
---|
114 | %{python_sitearch}/%{name}/*.py* |
---|
115 | %{python_sitearch}/%{name}/core |
---|
116 | %{python_sitearch}/%{name}/distutils |
---|
117 | %{python_sitearch}/%{name}/fft |
---|
118 | %{python_sitearch}/%{name}/lib |
---|
119 | %{python_sitearch}/%{name}/linalg |
---|
120 | %{python_sitearch}/%{name}/ma |
---|
121 | %{python_sitearch}/%{name}/numarray |
---|
122 | %{python_sitearch}/%{name}/oldnumeric |
---|
123 | %{python_sitearch}/%{name}/random |
---|
124 | %{python_sitearch}/%{name}/testing |
---|
125 | %{python_sitearch}/%{name}/tests |
---|
126 | %{python_sitearch}/%{name}/compat |
---|
127 | %{python_sitearch}/%{name}/matrixlib |
---|
128 | %{python_sitearch}/%{name}/polynomial |
---|
129 | %{python_sitearch}/%{name}-*.egg-info |
---|
130 | %{_includedir}/numpy |
---|
131 | |
---|
132 | %files f2py |
---|
133 | %defattr(-,root,root,-) |
---|
134 | %{_mandir}/man*/* |
---|
135 | %{_bindir}/f2py |
---|
136 | %{_bindir}/f2py.numpy |
---|
137 | %{python_sitearch}/%{name}/f2py |
---|
138 | |
---|
139 | |
---|
140 | %changelog |
---|
141 | * Wed Aug 25 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 1.4.1-8 |
---|
142 | - add Patch3(changeset_r8510.diff) and Patch4(changeset_r8511.diff) from debian |
---|
143 | |
---|
144 | * Fri Aug 20 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 1.4.1-7 |
---|
145 | - Initial build for Vine Linux |
---|
146 | |
---|
147 | * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-6 |
---|
148 | - actually add the patch this time |
---|
149 | |
---|
150 | * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-5 |
---|
151 | - fix segfault within %check on 2.7 (patch 2) |
---|
152 | |
---|
153 | * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-4 |
---|
154 | - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild |
---|
155 | |
---|
156 | * Sun Jul 18 2010 Dan Horák <dan[at]danny.cz> 1.4.1-3 |
---|
157 | - ignore the "Ticket #1299 second test" failure on s390(x) |
---|
158 | |
---|
159 | * Thu Jun 24 2010 Jef Spaleta <jspaleta@fedoraprject.org> 1.4.1-2 |
---|
160 | - source commit fix |
---|
161 | |
---|
162 | * Thu Jun 24 2010 Jef Spaleta <jspaleta@fedoraprject.org> 1.4.1-1 |
---|
163 | - New upstream release. Include backported doublefree patch |
---|
164 | |
---|
165 | * Mon Apr 26 2010 Jon Ciesla <limb@jcomserv.net> 1.3.0-8 |
---|
166 | - Moved distutils back to the main package, BZ 572820. |
---|
167 | |
---|
168 | * Thu Apr 08 2010 Jon Ciesla <limb@jcomserv.net> 1.3.0-7 |
---|
169 | - Reverted to 1.3.0 after upstream pulled 1.4.0, BZ 579065. |
---|
170 | |
---|
171 | * Tue Mar 02 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-5 |
---|
172 | - Linking /usr/include/numpy to .h files, BZ 185079. |
---|
173 | |
---|
174 | * Tue Feb 16 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-4 |
---|
175 | - Re-enabling atlas BR, dropping lapack Requires. |
---|
176 | |
---|
177 | * Wed Feb 10 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-3 |
---|
178 | - Since the previous didn't work, Requiring lapack. |
---|
179 | |
---|
180 | * Tue Feb 09 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-2 |
---|
181 | - Temporarily dropping atlas BR to work around 562577. |
---|
182 | |
---|
183 | * Fri Jan 22 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-1 |
---|
184 | - 1.4.0. |
---|
185 | - Dropped ARM patch, ARM support added upstream. |
---|
186 | |
---|
187 | * Tue Nov 17 2009 Jitesh Shah <jiteshs@marvell.com> - 1.3.0-6.fa1 |
---|
188 | - Add ARM support |
---|
189 | |
---|
190 | * Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.0-6 |
---|
191 | - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild |
---|
192 | |
---|
193 | * Thu Jun 11 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-5 |
---|
194 | - Fixed atlas BR, BZ 505376. |
---|
195 | |
---|
196 | * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-4 |
---|
197 | - EVR bump for pygame chainbuild. |
---|
198 | |
---|
199 | * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-3 |
---|
200 | - Moved linalg, fft back to main package. |
---|
201 | |
---|
202 | * Tue Apr 14 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-2 |
---|
203 | - Split out f2py into subpackage, thanks Peter Robinson pbrobinson@gmail.com. |
---|
204 | |
---|
205 | * Tue Apr 07 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-1 |
---|
206 | - Update to latest upstream. |
---|
207 | - Fixed Source0 URL. |
---|
208 | |
---|
209 | * Thu Apr 02 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-0.rc1 |
---|
210 | - Update to latest upstream. |
---|
211 | |
---|
212 | * Thu Mar 05 2009 Jon Ciesla <limb@jcomserv.net> 1.2.1-3 |
---|
213 | - Require python-devel, BZ 488464. |
---|
214 | |
---|
215 | * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.1-2 |
---|
216 | - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild |
---|
217 | |
---|
218 | * Fri Dec 19 2008 Jon Ciesla <limb@jcomserv.net> 1.2.1-1 |
---|
219 | - Update to 1.2.1. |
---|
220 | |
---|
221 | * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 1.2.0-2 |
---|
222 | - Rebuild for Python 2.6 |
---|
223 | |
---|
224 | * Tue Oct 07 2008 Jon Ciesla <limb@jcomserv.net> 1.2.0-1 |
---|
225 | - New upstream release, added python-nose BR. BZ 465999. |
---|
226 | - Using atlas blas, not blas-devel. BZ 461472. |
---|
227 | |
---|
228 | * Wed Aug 06 2008 Jon Ciesla <limb@jcomserv.net> 1.1.1-1 |
---|
229 | - New upstream release |
---|
230 | |
---|
231 | * Thu May 29 2008 Jarod Wilson <jwilson@redhat.com> 1.1.0-1 |
---|
232 | - New upstream release |
---|
233 | |
---|
234 | * Tue May 06 2008 Jarod Wilson <jwilson@redhat.com> 1.0.4-1 |
---|
235 | - New upstream release |
---|
236 | |
---|
237 | * Mon Feb 11 2008 Jarod Wilson <jwilson@redhat.com> 1.0.3.1-2 |
---|
238 | - Add python egg to %%files on f9+ |
---|
239 | |
---|
240 | * Wed Aug 22 2007 Jarod Wilson <jwilson@redhat.com> 1.0.3.1-1 |
---|
241 | - New upstream release |
---|
242 | |
---|
243 | * Wed Jun 06 2007 Jarod Wilson <jwilson@redhat.com> 1.0.3-1 |
---|
244 | - New upstream release |
---|
245 | |
---|
246 | * Mon May 14 2007 Jarod Wilson <jwilson@redhat.com> 1.0.2-2 |
---|
247 | - Drop BR: atlas-devel, since it just provides binary-compat |
---|
248 | blas and lapack libs. Atlas can still be optionally used |
---|
249 | at runtime. (Note: this is all per the atlas maintainer). |
---|
250 | |
---|
251 | * Mon May 14 2007 Jarod Wilson <jwilson@redhat.com> 1.0.2-1 |
---|
252 | - New upstream release |
---|
253 | |
---|
254 | * Tue Apr 17 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-4 |
---|
255 | - Update gfortran patch to recognize latest gfortran f95 support |
---|
256 | - Resolves rhbz#236444 |
---|
257 | |
---|
258 | * Fri Feb 23 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-3 |
---|
259 | - Fix up cpuinfo bug (#229753). Upstream bug/change: |
---|
260 | http://projects.scipy.org/scipy/scipy/ticket/349 |
---|
261 | |
---|
262 | * Thu Jan 04 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-2 |
---|
263 | - Per discussion w/Jose Matos, Obsolete/Provide f2py, as the |
---|
264 | stand-alone one is no longer supported/maintained upstream |
---|
265 | |
---|
266 | * Wed Dec 13 2006 Jarod Wilson <jwilson@redhat.com> 1.0.1-1 |
---|
267 | - New upstream release |
---|
268 | |
---|
269 | * Tue Dec 12 2006 Jarod Wilson <jwilson@redhat.com> 1.0-2 |
---|
270 | - Rebuild for python 2.5 |
---|
271 | |
---|
272 | * Wed Oct 25 2006 Jarod Wilson <jwilson@redhat.com> 1.0-1 |
---|
273 | - New upstream release |
---|
274 | |
---|
275 | * Tue Sep 06 2006 Jarod Wilson <jwilson@redhat.com> 0.9.8-1 |
---|
276 | - New upstream release |
---|
277 | |
---|
278 | * Wed Apr 26 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.6-1 |
---|
279 | - Upstream update |
---|
280 | |
---|
281 | * Thu Feb 16 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.5-1 |
---|
282 | - Upstream update |
---|
283 | |
---|
284 | * Mon Feb 13 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.4-2 |
---|
285 | - Rebuild for Fedora Extras 5 |
---|
286 | |
---|
287 | * Thu Feb 2 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.4-1 |
---|
288 | - Initial RPM release |
---|
289 | - Added gfortran patch from Neal Becker |
---|