◐ Shell
clean mode source ↗

gh-111225: Link extension modules against libpython on Android by mhsmith · Pull Request #115780 · python/cpython

@mhsmith

erlend-aasland

erlend-aasland

erlend-aasland

erlend-aasland

@erlend-aasland

erlend-aasland

woodruffw pushed a commit to woodruffw-forks/cpython that referenced this pull request

Mar 4, 2024
…ython#115780)

Part of the work on PEP 738: Adding Android as a supported platform.

* Rename the LIBPYTHON variable to MODULE_LDFLAGS, to more accurately 
  reflect its purpose.
* Edit makesetup to use MODULE_LDFLAGS when linking extension modules.
* Edit the Makefile so that extension modules depend on libpython on 
  Android and Cygwin.
* Restore `-fPIC` on Android. It was removed several years ago with a 
  note that the toolchain used it automatically, but this is no longer
  the case. Omitting it causes all linker commands to fail with an error
  like `relocation R_AARCH64_ADR_PREL_PG_HI21 cannot be used against
  symbol '_Py_FalseStruct'; recompile with -fPIC`.

This was referenced

Mar 13, 2024

tacaswell added a commit to tacaswell/cpython that referenced this pull request

Mar 13, 2024
Follow on to python#115780 .

Without this change numpy's build is broken.

befeleme pushed a commit to fedora-python/cpython that referenced this pull request

Mar 20, 2024
Follow on to python#115780 .

Without this change numpy's build is broken.

diegorusso pushed a commit to diegorusso/cpython that referenced this pull request

Apr 17, 2024
…ython#115780)

Part of the work on PEP 738: Adding Android as a supported platform.

* Rename the LIBPYTHON variable to MODULE_LDFLAGS, to more accurately 
  reflect its purpose.
* Edit makesetup to use MODULE_LDFLAGS when linking extension modules.
* Edit the Makefile so that extension modules depend on libpython on 
  Android and Cygwin.
* Restore `-fPIC` on Android. It was removed several years ago with a 
  note that the toolchain used it automatically, but this is no longer
  the case. Omitting it causes all linker commands to fail with an error
  like `relocation R_AARCH64_ADR_PREL_PG_HI21 cannot be used against
  symbol '_Py_FalseStruct'; recompile with -fPIC`.

LukasWoodtli pushed a commit to LukasWoodtli/cpython that referenced this pull request

Jan 22, 2025
…ython#115780)

Part of the work on PEP 738: Adding Android as a supported platform.

* Rename the LIBPYTHON variable to MODULE_LDFLAGS, to more accurately 
  reflect its purpose.
* Edit makesetup to use MODULE_LDFLAGS when linking extension modules.
* Edit the Makefile so that extension modules depend on libpython on 
  Android and Cygwin.
* Restore `-fPIC` on Android. It was removed several years ago with a 
  note that the toolchain used it automatically, but this is no longer
  the case. Omitting it causes all linker commands to fail with an error
  like `relocation R_AARCH64_ADR_PREL_PG_HI21 cannot be used against
  symbol '_Py_FalseStruct'; recompile with -fPIC`.

@lazka lazka mentioned this pull request

Sep 11, 2025