Skip to content

gh-160873: Remove obsolete pthread_getattr_np workaround - #160902

Open
lpyu001 wants to merge 1 commit into
python:mainfrom
lpyu001:cpython-lpy/emscripten-m64-pthread
Open

lpyu001 wants to merge 1 commit into
python:mainfrom
lpyu001:cpython-lpy/emscripten-m64-pthread

Conversation

@lpyu001

@lpyu001 lpyu001 commented Oct 29, 2026 •

Copy link
Copy Markdown
Contributor

Emscripten 6.0.1 deprecated -sUSE_PTHREADS and -sMEMORY64 in favor of the standard -pthread and -m64 flags (emscripten-core/emscripten#27025). With the currently pinned Emscripten 6.0.10, both emit a -Wdeprecated warning at link time:

emcc: warning: USE_PTHREADS is deprecated (prefer the standard -pthread flag). [-Wdeprecated]
emcc: warning: MEMORY64 is deprecated (prefer the standard -m64 or --target=wasm64 flags). [-Wdeprecated]

This PR switches configure.ac to the standard flags:

  • --enable-wasm-pthreads: -sUSE_PTHREADS → -pthread in LDFLAGS_NODIST. The existing -pthread in CFLAGS_NODIST is not passed to the link step, so the linker flag is still needed.
  • wasm64-*-emscripten: -sMEMORY64=1 → -m64 in CFLAGS and LDFLAGS.
  • Platforms/emscripten/README.md is updated to match.

I've also removed the Emscripten-specific NDOTDOTS = 48 workaround from test_glob_dotdot in Lib/test/test_pathlib/test_pathlib.py. Its comment says it can be removed once emscripten-core/emscripten#24591 is merged. That PR (don't return ELOOP on a path with many .. components) was merged in June 2025 and should be in 4.0.11 and later, well below the pinned 6.0.10. The test now uses NDOTDOTS = 50 on all platforms.

@lpyu001

lpyu001 commented Oct 30, 2026

Copy link
Copy Markdown
Contributor Author

cc @hoodmane

@hoodmane

Copy link
Copy Markdown
Contributor

Looks good to me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants