[12283] | 1 | %bcond_with check |
---|
| 2 | |
---|
[1636] | 3 | # eval to 2.3 if python isn't yet present, workaround for no python in fc4 minimal buildroot |
---|
| 4 | %{!?python_version: %define python_version %(%{__python} -c 'import sys; print sys.version.split(" ")[0]' || echo "2.3")} |
---|
| 5 | |
---|
| 6 | Name: numpy |
---|
| 7 | Summary: A fast multidimensional array facility for Python |
---|
[12469] | 8 | Version: 1.19.1 |
---|
[12283] | 9 | Release: 1%{?_dist_release} |
---|
[12469] | 10 | Group: programming |
---|
[12283] | 11 | Vendor: Project Vine |
---|
| 12 | Distribution: Vine Linux |
---|
| 13 | |
---|
| 14 | License: BSD and Python and ASL 2.0 |
---|
| 15 | URL: https://www.numpy.org/ |
---|
| 16 | Source0: https://github.com/%{name}/%{name}/releases/download/v%{version}/%{name}-%{version}.tar.gz |
---|
[12469] | 17 | Source1: https://docs.scipy.org/doc/numpy/numpy-html-1.17.0.zip |
---|
[12283] | 18 | |
---|
| 19 | BuildRoot: %{_tmppath}/%{name}-%{version}-root |
---|
[1636] | 20 | |
---|
[12283] | 21 | BuildRequires: gcc-gfortran gcc |
---|
| 22 | BuildRequires: lapack-devel |
---|
| 23 | BuildRequires: openblas-devel |
---|
[12469] | 24 | BuildRequires: python-rpm-macros |
---|
[1671] | 25 | |
---|
[12469] | 26 | BuildRequires: python3-devel |
---|
| 27 | BuildRequires: python3-rpm-macros |
---|
| 28 | BuildRequires: python3-setuptools |
---|
| 29 | %if %{with check} |
---|
| 30 | BuildRequires: python3-pytest |
---|
| 31 | %endif |
---|
| 32 | BuildRequires: python3-Cython |
---|
[1636] | 33 | |
---|
| 34 | %description |
---|
| 35 | NumPy is a general-purpose array-processing package designed to |
---|
| 36 | efficiently manipulate large multi-dimensional arrays of arbitrary |
---|
| 37 | records without sacrificing too much speed for small multi-dimensional |
---|
| 38 | arrays. NumPy is built on the Numeric code base and adds features |
---|
| 39 | introduced by numarray as well as an extended C-API and the ability to |
---|
| 40 | create arrays of arbitrary type. |
---|
| 41 | |
---|
| 42 | There are also basic facilities for discrete fourier transform, |
---|
| 43 | basic linear algebra and random number generation. Also included in |
---|
| 44 | this package is a version of f2py that works properly with NumPy. |
---|
| 45 | |
---|
[12283] | 46 | |
---|
| 47 | %package -n python3-numpy |
---|
| 48 | Summary: A fast multidimensional array facility for Python |
---|
[12469] | 49 | Group: programming |
---|
[12283] | 50 | |
---|
| 51 | License: BSD |
---|
| 52 | %{?python_provide:%python_provide python3-numpy} |
---|
| 53 | Provides: libnpymath-static = %{version}-%{release} |
---|
| 54 | Provides: libnpymath-static%{?_isa} = %{version}-%{release} |
---|
[12469] | 55 | Obsoletes: numpy-common < 1.19.0 |
---|
| 56 | Conflicts: numpy-common < 1.19.0 |
---|
[12283] | 57 | |
---|
| 58 | %description -n python3-numpy |
---|
| 59 | NumPy is a general-purpose array-processing package designed to |
---|
| 60 | efficiently manipulate large multi-dimensional arrays of arbitrary |
---|
| 61 | records without sacrificing too much speed for small multi-dimensional |
---|
| 62 | arrays. NumPy is built on the Numeric code base and adds features |
---|
| 63 | introduced by numarray as well as an extended C-API and the ability to |
---|
| 64 | create arrays of arbitrary type. |
---|
| 65 | |
---|
| 66 | There are also basic facilities for discrete fourier transform, |
---|
| 67 | basic linear algebra and random number generation. Also included in |
---|
| 68 | this package is a version of f2py that works properly with NumPy. |
---|
| 69 | |
---|
| 70 | |
---|
| 71 | %package -n python3-numpy-f2py |
---|
| 72 | Summary: f2py for numpy |
---|
[12469] | 73 | Group: programming |
---|
[12283] | 74 | Requires: python3-numpy%{?_isa} = %{version}-%{release} |
---|
| 75 | Requires: python3-devel |
---|
| 76 | Provides: python3-f2py = %{version}-%{release} |
---|
| 77 | %{?python_provide:%python_provide python3-numpy-f2py} |
---|
| 78 | |
---|
| 79 | %description -n python3-numpy-f2py |
---|
| 80 | This package includes a version of f2py that works properly with NumPy. |
---|
| 81 | |
---|
| 82 | |
---|
| 83 | %package -n python3-numpy-doc |
---|
| 84 | Summary: Documentation for numpy |
---|
[12469] | 85 | Group: documentation |
---|
[12283] | 86 | Requires: python3-numpy = %{version}-%{release} |
---|
| 87 | BuildArch: noarch |
---|
| 88 | |
---|
| 89 | %description -n python3-numpy-doc |
---|
| 90 | This package provides the complete documentation for NumPy. |
---|
| 91 | |
---|
| 92 | |
---|
[1636] | 93 | %prep |
---|
| 94 | %setup -q -n %{name}-%{version} |
---|
[12283] | 95 | # Force re-cythonization (ifed for PKG-INFO presence in setup.py) |
---|
| 96 | rm -f PKG-INFO |
---|
| 97 | # Use openblas pthreads as recommended by upstream (see comment in site.cfg.example) |
---|
| 98 | cat >> site.cfg <<EOF |
---|
| 99 | [openblas] |
---|
| 100 | libraries = openblasp |
---|
| 101 | library_dirs = %{_libdir} |
---|
| 102 | EOF |
---|
| 103 | |
---|
[1636] | 104 | |
---|
[12469] | 105 | %build |
---|
[12283] | 106 | env OPENBLAS=%{_libdir} \ |
---|
| 107 | BLAS=%{_libdir} \ |
---|
| 108 | LAPACK=%{_libdir} CFLAGS="%{optflags}" \ |
---|
| 109 | %{__python3} setup.py build |
---|
| 110 | |
---|
[12469] | 111 | |
---|
[1636] | 112 | %install |
---|
[12283] | 113 | rm -rf %{buildroot} |
---|
| 114 | |
---|
| 115 | mkdir docs |
---|
| 116 | pushd docs |
---|
| 117 | unzip %{SOURCE1} |
---|
| 118 | popd |
---|
| 119 | |
---|
[1636] | 120 | |
---|
[12283] | 121 | env OPENBLAS=%{_libdir} \ |
---|
| 122 | FFTW=%{_libdir} BLAS=%{_libdir} \ |
---|
| 123 | LAPACK=%{_libdir} CFLAGS="%{optflags}" \ |
---|
| 124 | %{__python3} setup.py install --root %{buildroot} |
---|
| 125 | pushd %{buildroot}%{_bindir} &> /dev/null |
---|
| 126 | ln -s f2py3 f2py.numpy |
---|
| 127 | popd &> /dev/null |
---|
| 128 | |
---|
[1636] | 129 | #symlink for includes, BZ 185079 |
---|
[12283] | 130 | mkdir -p %{buildroot}%{_includedir} |
---|
[12469] | 131 | ln -s %{python3_sitearch}/%{name}/core/include/numpy/ %{buildroot}%{_includedir}/numpy |
---|
[1636] | 132 | |
---|
| 133 | |
---|
[12283] | 134 | %if %{with check} |
---|
[1636] | 135 | %check |
---|
[12469] | 136 | python3 runtests.py |
---|
[12283] | 137 | %endif |
---|
[1636] | 138 | |
---|
[12469] | 139 | |
---|
[1636] | 140 | %clean |
---|
| 141 | rm -rf $RPM_BUILD_ROOT |
---|
| 142 | |
---|
[12283] | 143 | |
---|
[12469] | 144 | %pretrans -n python3-numpy -p <lua> |
---|
| 145 | -- Define the path to directory being replaced below. |
---|
| 146 | -- DO NOT add a trailing slash at the end. |
---|
| 147 | path = "%{_includedir}/numpy" |
---|
| 148 | st = posix.stat(path) |
---|
| 149 | if st and st.type == "directory" then |
---|
| 150 | status = os.rename(path, path .. ".rpmmoved") |
---|
| 151 | if not status then |
---|
| 152 | suffix = 0 |
---|
| 153 | while not status do |
---|
| 154 | suffix = suffix + 1 |
---|
| 155 | status = os.rename(path .. ".rpmmoved", path .. ".rpmmoved." .. suffix) |
---|
| 156 | end |
---|
| 157 | os.rename(path, path .. ".rpmmoved") |
---|
| 158 | end |
---|
| 159 | end |
---|
[1636] | 160 | |
---|
[12283] | 161 | |
---|
| 162 | %files -n python3-numpy |
---|
| 163 | %license LICENSE.txt |
---|
| 164 | %doc THANKS.txt site.cfg.example |
---|
| 165 | %dir %{python3_sitearch}/%{name} |
---|
[12469] | 166 | %{python3_sitearch}/%{name}/*.py* |
---|
| 167 | %{python3_sitearch}/%{name}/__pycache__ |
---|
| 168 | %{python3_sitearch}/%{name}/core |
---|
| 169 | %{python3_sitearch}/%{name}/distutils |
---|
| 170 | %{python3_sitearch}/%{name}/doc |
---|
| 171 | %{python3_sitearch}/%{name}/fft |
---|
| 172 | %{python3_sitearch}/%{name}/lib |
---|
| 173 | %{python3_sitearch}/%{name}/linalg |
---|
| 174 | %{python3_sitearch}/%{name}/ma |
---|
| 175 | %{python3_sitearch}/%{name}/random |
---|
| 176 | %{python3_sitearch}/%{name}/testing |
---|
| 177 | %{python3_sitearch}/%{name}/tests |
---|
| 178 | %{python3_sitearch}/%{name}/compat |
---|
| 179 | %{python3_sitearch}/%{name}/matrixlib |
---|
| 180 | %{python3_sitearch}/%{name}/polynomial |
---|
[12283] | 181 | %{python3_sitearch}/%{name}-*.egg-info |
---|
| 182 | %exclude %{python3_sitearch}/%{name}/LICENSE.txt |
---|
[12469] | 183 | %{_includedir}/numpy |
---|
| 184 | %{python3_sitearch}/%{name}/__init__.pxd |
---|
[12283] | 185 | |
---|
| 186 | %files -n python3-numpy-f2py |
---|
[1636] | 187 | %{_bindir}/f2py |
---|
[12283] | 188 | %{_bindir}/f2py3 |
---|
[1636] | 189 | %{_bindir}/f2py.numpy |
---|
[12283] | 190 | %{_bindir}/f2py%{python3_version} |
---|
| 191 | %{python3_sitearch}/%{name}/f2py |
---|
[1636] | 192 | |
---|
[12283] | 193 | %files -n python3-numpy-doc |
---|
| 194 | %doc docs/* |
---|
[1636] | 195 | |
---|
[12283] | 196 | |
---|
[1636] | 197 | %changelog |
---|
[12469] | 198 | * Sat Aug 15 2020 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.19.1-1 |
---|
| 199 | - new upstream release. |
---|
| 200 | - built with python3 only. |
---|
| 201 | |
---|
[12283] | 202 | * Wed Oct 23 2019 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> - 1.16.5-1 |
---|
| 203 | - new upstream release: this version is not newest but final version to suppot python2. |
---|
| 204 | - added python3 support. |
---|
| 205 | |
---|
[5701] | 206 | * Sun Feb 19 2012 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 1.4.1-9 |
---|
| 207 | - rebuild with python-2.7.2 |
---|
| 208 | |
---|
[1671] | 209 | * Wed Aug 25 2010 Yoji TOYODA <bsyamato@sea.plala.or.jp> - 1.4.1-8 |
---|
| 210 | - add Patch3(changeset_r8510.diff) and Patch4(changeset_r8511.diff) from debian |
---|
| 211 | |
---|
[1636] | 212 | * Fri Aug 20 2010 Ryoichi INAGAKI <ryo1@bc.wakwak.com> - 1.4.1-7 |
---|
| 213 | - Initial build for Vine Linux |
---|
| 214 | |
---|
| 215 | * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-6 |
---|
| 216 | - actually add the patch this time |
---|
| 217 | |
---|
| 218 | * Thu Jul 22 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-5 |
---|
| 219 | - fix segfault within %check on 2.7 (patch 2) |
---|
| 220 | |
---|
| 221 | * Wed Jul 21 2010 David Malcolm <dmalcolm@redhat.com> - 1:1.4.1-4 |
---|
| 222 | - Rebuilt for https://fedoraproject.org/wiki/Features/Python_2.7/MassRebuild |
---|
| 223 | |
---|
| 224 | * Sun Jul 18 2010 Dan Horák <dan[at]danny.cz> 1.4.1-3 |
---|
| 225 | - ignore the "Ticket #1299 second test" failure on s390(x) |
---|
| 226 | |
---|
| 227 | * Thu Jun 24 2010 Jef Spaleta <jspaleta@fedoraprject.org> 1.4.1-2 |
---|
| 228 | - source commit fix |
---|
| 229 | |
---|
| 230 | * Thu Jun 24 2010 Jef Spaleta <jspaleta@fedoraprject.org> 1.4.1-1 |
---|
| 231 | - New upstream release. Include backported doublefree patch |
---|
| 232 | |
---|
| 233 | * Mon Apr 26 2010 Jon Ciesla <limb@jcomserv.net> 1.3.0-8 |
---|
| 234 | - Moved distutils back to the main package, BZ 572820. |
---|
| 235 | |
---|
| 236 | * Thu Apr 08 2010 Jon Ciesla <limb@jcomserv.net> 1.3.0-7 |
---|
| 237 | - Reverted to 1.3.0 after upstream pulled 1.4.0, BZ 579065. |
---|
| 238 | |
---|
| 239 | * Tue Mar 02 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-5 |
---|
| 240 | - Linking /usr/include/numpy to .h files, BZ 185079. |
---|
| 241 | |
---|
| 242 | * Tue Feb 16 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-4 |
---|
| 243 | - Re-enabling atlas BR, dropping lapack Requires. |
---|
| 244 | |
---|
| 245 | * Wed Feb 10 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-3 |
---|
| 246 | - Since the previous didn't work, Requiring lapack. |
---|
| 247 | |
---|
| 248 | * Tue Feb 09 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-2 |
---|
| 249 | - Temporarily dropping atlas BR to work around 562577. |
---|
| 250 | |
---|
| 251 | * Fri Jan 22 2010 Jon Ciesla <limb@jcomserv.net> 1.4.0-1 |
---|
| 252 | - 1.4.0. |
---|
| 253 | - Dropped ARM patch, ARM support added upstream. |
---|
| 254 | |
---|
| 255 | * Tue Nov 17 2009 Jitesh Shah <jiteshs@marvell.com> - 1.3.0-6.fa1 |
---|
| 256 | - Add ARM support |
---|
| 257 | |
---|
| 258 | * Sat Jul 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.3.0-6 |
---|
| 259 | - Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild |
---|
| 260 | |
---|
| 261 | * Thu Jun 11 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-5 |
---|
| 262 | - Fixed atlas BR, BZ 505376. |
---|
| 263 | |
---|
| 264 | * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-4 |
---|
| 265 | - EVR bump for pygame chainbuild. |
---|
| 266 | |
---|
| 267 | * Fri Apr 17 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-3 |
---|
| 268 | - Moved linalg, fft back to main package. |
---|
| 269 | |
---|
| 270 | * Tue Apr 14 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-2 |
---|
| 271 | - Split out f2py into subpackage, thanks Peter Robinson pbrobinson@gmail.com. |
---|
| 272 | |
---|
| 273 | * Tue Apr 07 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-1 |
---|
| 274 | - Update to latest upstream. |
---|
| 275 | - Fixed Source0 URL. |
---|
| 276 | |
---|
| 277 | * Thu Apr 02 2009 Jon Ciesla <limb@jcomserv.net> 1.3.0-0.rc1 |
---|
| 278 | - Update to latest upstream. |
---|
| 279 | |
---|
| 280 | * Thu Mar 05 2009 Jon Ciesla <limb@jcomserv.net> 1.2.1-3 |
---|
| 281 | - Require python-devel, BZ 488464. |
---|
| 282 | |
---|
| 283 | * Wed Feb 25 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.2.1-2 |
---|
| 284 | - Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild |
---|
| 285 | |
---|
| 286 | * Fri Dec 19 2008 Jon Ciesla <limb@jcomserv.net> 1.2.1-1 |
---|
| 287 | - Update to 1.2.1. |
---|
| 288 | |
---|
| 289 | * Sat Nov 29 2008 Ignacio Vazquez-Abrams <ivazqueznet+rpm@gmail.com> - 1.2.0-2 |
---|
| 290 | - Rebuild for Python 2.6 |
---|
| 291 | |
---|
| 292 | * Tue Oct 07 2008 Jon Ciesla <limb@jcomserv.net> 1.2.0-1 |
---|
| 293 | - New upstream release, added python-nose BR. BZ 465999. |
---|
| 294 | - Using atlas blas, not blas-devel. BZ 461472. |
---|
| 295 | |
---|
| 296 | * Wed Aug 06 2008 Jon Ciesla <limb@jcomserv.net> 1.1.1-1 |
---|
| 297 | - New upstream release |
---|
| 298 | |
---|
| 299 | * Thu May 29 2008 Jarod Wilson <jwilson@redhat.com> 1.1.0-1 |
---|
| 300 | - New upstream release |
---|
| 301 | |
---|
| 302 | * Tue May 06 2008 Jarod Wilson <jwilson@redhat.com> 1.0.4-1 |
---|
| 303 | - New upstream release |
---|
| 304 | |
---|
| 305 | * Mon Feb 11 2008 Jarod Wilson <jwilson@redhat.com> 1.0.3.1-2 |
---|
| 306 | - Add python egg to %%files on f9+ |
---|
| 307 | |
---|
| 308 | * Wed Aug 22 2007 Jarod Wilson <jwilson@redhat.com> 1.0.3.1-1 |
---|
| 309 | - New upstream release |
---|
| 310 | |
---|
| 311 | * Wed Jun 06 2007 Jarod Wilson <jwilson@redhat.com> 1.0.3-1 |
---|
| 312 | - New upstream release |
---|
| 313 | |
---|
| 314 | * Mon May 14 2007 Jarod Wilson <jwilson@redhat.com> 1.0.2-2 |
---|
| 315 | - Drop BR: atlas-devel, since it just provides binary-compat |
---|
| 316 | blas and lapack libs. Atlas can still be optionally used |
---|
| 317 | at runtime. (Note: this is all per the atlas maintainer). |
---|
| 318 | |
---|
| 319 | * Mon May 14 2007 Jarod Wilson <jwilson@redhat.com> 1.0.2-1 |
---|
| 320 | - New upstream release |
---|
| 321 | |
---|
| 322 | * Tue Apr 17 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-4 |
---|
| 323 | - Update gfortran patch to recognize latest gfortran f95 support |
---|
| 324 | - Resolves rhbz#236444 |
---|
| 325 | |
---|
| 326 | * Fri Feb 23 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-3 |
---|
| 327 | - Fix up cpuinfo bug (#229753). Upstream bug/change: |
---|
| 328 | http://projects.scipy.org/scipy/scipy/ticket/349 |
---|
| 329 | |
---|
| 330 | * Thu Jan 04 2007 Jarod Wilson <jwilson@redhat.com> 1.0.1-2 |
---|
| 331 | - Per discussion w/Jose Matos, Obsolete/Provide f2py, as the |
---|
| 332 | stand-alone one is no longer supported/maintained upstream |
---|
| 333 | |
---|
| 334 | * Wed Dec 13 2006 Jarod Wilson <jwilson@redhat.com> 1.0.1-1 |
---|
| 335 | - New upstream release |
---|
| 336 | |
---|
| 337 | * Tue Dec 12 2006 Jarod Wilson <jwilson@redhat.com> 1.0-2 |
---|
| 338 | - Rebuild for python 2.5 |
---|
| 339 | |
---|
| 340 | * Wed Oct 25 2006 Jarod Wilson <jwilson@redhat.com> 1.0-1 |
---|
| 341 | - New upstream release |
---|
| 342 | |
---|
[12283] | 343 | * Wed Sep 06 2006 Jarod Wilson <jwilson@redhat.com> 0.9.8-1 |
---|
[1636] | 344 | - New upstream release |
---|
| 345 | |
---|
| 346 | * Wed Apr 26 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.6-1 |
---|
| 347 | - Upstream update |
---|
| 348 | |
---|
| 349 | * Thu Feb 16 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.5-1 |
---|
| 350 | - Upstream update |
---|
| 351 | |
---|
| 352 | * Mon Feb 13 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.4-2 |
---|
| 353 | - Rebuild for Fedora Extras 5 |
---|
| 354 | |
---|
| 355 | * Thu Feb 2 2006 Ignacio Vazquez-Abrams <ivazquez@ivazquez.net> 0.9.4-1 |
---|
| 356 | - Initial RPM release |
---|
| 357 | - Added gfortran patch from Neal Becker |
---|