Skip to content

Commit

Permalink
Trac #34110: numpy 1.23.x
Browse files Browse the repository at this point in the history
(split out from #34081)

​https://numpy.org/doc/stable/release/1.23.0-notes.html# (released)

The upgrade looks harmless.

1.23.x requires GCC >= 6.5. (This has been documented in
numpy/numpy#22155 - to be included in 1.23.3.)

We set #34266 as a dependency, which increases our requirement from GCC
>= 6.3 to GCC >= 8)

Previous update:

#32423 Update numpy to 1.22.x, scipy 1.8.x, networkx 2.8.x

URL: https://trac.sagemath.org/34110
Reported by: mkoeppe
Ticket author(s): Matthias Koeppe
Reviewer(s): Dima Pasechnik, John Palmieri
  • Loading branch information
Release Manager committed Sep 27, 2022
2 parents 025fdd4 + 03fad7d commit 5076cd5
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 12 deletions.
10 changes: 5 additions & 5 deletions build/pkgs/numpy/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
tarball=numpy-VERSION.zip
sha1=3ac08064b2ec8db8fe4870c2545c9d154f46bb30
md5=b44849506fbb54cdef9dbb435b2b1987
cksum=735479084
upstream_url=https://pypi.io/packages/source/n/numpy/numpy-VERSION.zip
tarball=numpy-VERSION.tar.gz
sha1=570c995d7b155c7e4ac43bc46594172cedf1e4fa
md5=6efc60a3f6c1b74c849d53fbcc07807b
cksum=3973735135
upstream_url=https://pypi.io/packages/source/n/numpy/numpy-VERSION.tar.gz
2 changes: 1 addition & 1 deletion build/pkgs/numpy/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
1.22.4
1.23.3
15 changes: 9 additions & 6 deletions build/pkgs/numpy/spkg-install.in
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,14 @@ if [ `uname` = "Darwin" ]; then
unset ATLAS
unset BLAS
unset LAPACK
# https://trac.sagemath.org/ticket/34110#comment:35
# The fix for "reciprocal" (affected by a clang compiler bug) in
# https://github.com/numpy/numpy/pull/19926 relies on -ftrapping-math
# being used when Apple clang v12+ is used.
# But numpy.distutils.ccompiler only sets this flag when
# $CC contains the string "clang" -- missing the case CC=/usr/bin/gcc.
# So we set it here explicitly if the compiler supports the flag.
export CFLAGS="$(testcflags.sh $CFLAGS -ftrapping-math)"
else
export {ATLAS,PTATLAS,OPENBLAS,MKL,MKLROOT}=None
export LDFLAGS="${LDFLAGS} -shared"
Expand All @@ -27,15 +35,10 @@ fi
export FFLAGS="$FFLAGS -fPIC"
export FCFLAGS="$FCFLAGS -fPIC"

# Numpy 1.20.3 enables some intrinsics on machines without support with `-march=native`.
# We disable it until this is fixed.
export CFLAGS="$CFLAGS_NON_NATIVE"

export NUMPY_FCONFIG="config_fc --noopt --noarch"
if [ "$SAGE_FAT_BINARY" = "yes" ]; then
export NUMPY_FCONFIG="--cpu-baseline=NONE"
else
export NUMPY_FCONFIG
export NUMPY_FCONFIG=""
fi

# Trac #32423: Fix 32-bit builds on x86_64
Expand Down

0 comments on commit 5076cd5

Please sign in to comment.