Repository navigation
[3.14] gh-104612: Document linking embedders for several Python versions (GH-162498) - #162761
Merged
Merged
Conversation
… versions (pythonGH-162498) Add a section to the embedding guide that explains, for Linux, that linking with `pythonX.Y-config --ldflags --embed` ties an application to one minor version even when it only uses the Limited API, and how a single binary can instead load `libpython3.so` at run time. Mention renaming the dependency with `patchelf` as a packaging workaround, and list the limitations of both approaches. Related discussion: https://discuss.python.org/t/on-embedders-and-stable-abi/110197 (cherry picked from commit cb9d78f) Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com>
Documentation build overview
329 files changed ·
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add a section to the embedding guide that explains, for Linux, that linking with
pythonX.Y-config --ldflags --embedties an application to one minor version even when it only uses the Limited API, and how a single binary can instead loadlibpython3.soat run time. Mention renaming the dependency withpatchelfas a packaging workaround, and list the limitations of both approaches.Related discussion: https://discuss.python.org/t/on-embedders-and-stable-abi/110197
(cherry picked from commit cb9d78f)
Manual backport; the automated one hit a conflict in
Doc/c-api/stable.rst, which is organized differently on 3.14:main.limited-api-caveatslabel, which the new section links to, does not exist on 3.14, so it is added above the "Limited API Caveats" heading.Doc/extending/embedding.rstapplied cleanly and is identical tomain. The docs build on this branch with--fail-on-warning.🤖 Generated with Claude Code