Skip to content

Commit c76e70a

Browse files
gh-93358: Fix python-config docs for how to embed Python (GH-98649)
(cherry picked from commit e063c23) Co-authored-by: Erlend E. Aasland <[email protected]>
1 parent 85f88f6 commit c76e70a

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

Doc/extending/embedding.rst

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -298,16 +298,16 @@ be directly useful to you:
298298

299299
.. code-block:: shell-session
300300
301-
$ /opt/bin/python3.4-config --cflags
302-
-I/opt/include/python3.4m -I/opt/include/python3.4m -DNDEBUG -g -fwrapv -O3 -Wall -Wstrict-prototypes
301+
$ /opt/bin/python3.11-config --cflags
302+
-I/opt/include/python3.11 -I/opt/include/python3.11 -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall
303303
304-
* ``pythonX.Y-config --ldflags`` will give you the recommended flags when
305-
linking:
304+
* ``pythonX.Y-config --ldflags --embed`` will give you the recommended flags
305+
when linking:
306306

307307
.. code-block:: shell-session
308308
309-
$ /opt/bin/python3.4-config --ldflags
310-
-L/opt/lib/python3.4/config-3.4m -lpthread -ldl -lutil -lm -lpython3.4m -Xlinker -export-dynamic
309+
$ /opt/bin/python3.11-config --ldflags --embed
310+
-L/opt/lib/python3.11/config-3.11-x86_64-linux-gnu -L/opt/lib -lpython3.11 -lpthread -ldl -lutil -lm
311311
312312
.. note::
313313
To avoid confusion between several Python installations (and especially

0 commit comments

Comments
 (0)