Skip to content

Commit

Permalink
sagemathgh-37914: build/pkgs/python3: Update to 3.11.8, remove Cygw…
Browse files Browse the repository at this point in the history
…in patches, remove pointless rpaths on macOS

    
<!-- ^ Please provide a concise and informative title. -->
<!-- ^ Don't put issue numbers in the title, do this in the PR
description below. -->
<!-- ^ For example, instead of "Fixes sagemath#12345" use "Introduce new method
to calculate 1 + 2". -->
<!-- v Describe your changes below in detail. -->
<!-- v Why is this change required? What problem does it solve? -->
<!-- v If this PR resolves an open issue, please link to it here. For
example, "Fixes sagemath#12345". -->

Author: @culler

Split out from:
- sagemath#37886

### 📝 Checklist

<!-- Put an `x` in all the boxes that apply. -->

- [x] The title is concise and informative.
- [ ] The description explains in detail what this PR is about.
- [x] I have linked a relevant issue or discussion.
- [ ] I have created tests covering the changes.
- [ ] I have updated the documentation and checked the documentation
preview.

### ⌛ Dependencies

<!-- List all open PRs that this PR logically depends on. For example,
-->
<!-- - sagemath#12345: short description why this is a dependency -->
<!-- - sagemath#34567: ... -->
    
URL: sagemath#37914
Reported by: Matthias Köppe
Reviewer(s):
  • Loading branch information
Release Manager committed May 4, 2024
2 parents 4bc1e93 + 9a6c210 commit 48fff2e
Show file tree
Hide file tree
Showing 6 changed files with 17 additions and 100 deletions.
6 changes: 3 additions & 3 deletions build/pkgs/python3/checksums.ini
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
tarball=Python-VERSION.tar.xz
sha1=89ee31611b73dc0c32c178d15aa208734b462c5a
md5=4efe92adf28875c77d3b9b2e8d3bc44a
cksum=2916176597
sha1=a368aeed7a3325e47b55168452c356a8eb27ab50
md5=b353b8433e560e1af2b130f56dfbd973
cksum=534846730
upstream_url=https://www.python.org/ftp/python/VERSION/Python-VERSION.tar.xz
2 changes: 1 addition & 1 deletion build/pkgs/python3/package-version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
3.11.1
3.11.8
47 changes: 0 additions & 47 deletions build/pkgs/python3/patches/2.6.5-FD_SETSIZE.patch

This file was deleted.

15 changes: 0 additions & 15 deletions build/pkgs/python3/patches/2.7.3-dylib.patch

This file was deleted.

22 changes: 0 additions & 22 deletions build/pkgs/python3/patches/3.2.6-no-enable-new-dtags.patch

This file was deleted.

25 changes: 13 additions & 12 deletions build/pkgs/python3/spkg-build.in
Original file line number Diff line number Diff line change
Expand Up @@ -73,25 +73,26 @@ sdh_configure --enable-shared $PYTHON_CONFIGURE
# we need to provide paths into $SAGE_LOCAL, so that setup.py finds
# the libraries needed for the extension modules - in particular sqlite3.
# (The search code there does not know about CPATH and LIBRARY_PATH.)
make_LDFLAGS="-L. -Wl,-rpath,. -L$SAGE_LOCAL/lib $LDFLAGS"
make_CPPFLAGS="-I$SAGE_LOCAL/include $CPPFLAGS"

# Also, we need to add an rpath, like we do for SAGE_LOCAL in src/bin/sage-env.
# SAGE_INST_LOCAL is the installation hierarchy for the current package
# -- for python3, this is SAGE_VENV.
make_LDFLAGS="-Wl,-rpath,$SAGE_INST_LOCAL/lib $make_LDFLAGS"
if [ "$UNAME" = "Darwin" ]; then
make_LDFLAGS="-L$SAGE_LOCAL/lib -L$SAGE_INST_LOCAL/lib $LDFLAGS"
# This enables python to find libpython
export DYLD_LIBRARY_PATH="."
fi
if [ "$UNAME" = "Linux" ]; then
make_LDFLAGS="-L. -Wl,-rpath,. -L$SAGE_LOCAL/lib $LDFLAGS"
make_CPPFLAGS="-I$SAGE_LOCAL/include $CPPFLAGS"
# Also, we need to add an rpath, like we do for SAGE_LOCAL in src/bin/sage-env.
# SAGE_INST_LOCAL is the installation hierarchy for the current package
# -- for python3, this is SAGE_VENV.
make_LDFLAGS="-Wl,-rpath,$SAGE_INST_LOCAL/lib $make_LDFLAGS"
make_LDFLAGS="-Wl,-rpath-link,$SAGE_INST_LOCAL/lib $make_LDFLAGS"
# This enables python to find libpython
export LD_LIBRARY_PATH="."
fi

sdh_make LDFLAGS="$make_LDFLAGS" CPPFLAGS="$make_CPPFLAGS"

if [ "$UNAME" = "Darwin" ]; then
export DYLD_LIBRARY_PATH="."
else
export LD_LIBRARY_PATH="."
fi

# When building on a case-insensitive filesystem (on any OS, not just Windows)
# the Python executable is output to the build directory as 'python.exe'
if [ -f "python.exe" ]; then
Expand Down

0 comments on commit 48fff2e

Please sign in to comment.