From 9b3fc31f2330c1186f6f4ed736f6e6c7d4c2fd1f Mon Sep 17 00:00:00 2001 From: Victor Stinner Date: Sun, 10 Sep 2023 12:55:47 +0200 Subject: [PATCH] gh-109054: Document configue options --- Doc/library/hashlib.rst | 2 + Doc/using/configure.rst | 150 ++++++++++++++++++++++++++++++++++++++++ 2 files changed, 152 insertions(+) diff --git a/Doc/library/hashlib.rst b/Doc/library/hashlib.rst index 69fb79b49ca2a05..68f922fdee6ce86 100644 --- a/Doc/library/hashlib.rst +++ b/Doc/library/hashlib.rst @@ -364,6 +364,8 @@ include a `salt `_. .. versionadded:: 3.6 +.. _hashlib-blake2: + BLAKE2 ------ diff --git a/Doc/using/configure.rst b/Doc/using/configure.rst index ba1898e35b5fbc2..dc8c1bf107f5b33 100644 --- a/Doc/using/configure.rst +++ b/Doc/using/configure.rst @@ -94,6 +94,154 @@ List all :file:`configure` script options using:: See also the :file:`Misc/SpecialBuilds.txt` in the Python source distribution. +Variables +--------- + +.. cmdoption:: BOLT_APPLY_FLAGS + + Arguments to ``llvm-bolt`` when creating a `BOLT optimized binary + `_. + +.. cmdoption:: BOLT_INSTRUMENT_FLAGS + + Arguments to ``llvm-bolt`` when instrumenting binaries. + +.. cmdoption:: BZIP2_CFLAGS +.. cmdoption:: BZIP2_LIBS + + C compiler and linker flags to link Python to ``libbz2``, used by :mod:`bz2` + module, overriding ``pkg-config``. + +.. cmdoption:: CC + + C compiler command. + +.. cmdoption:: CFLAGS + + C compiler flags. + +.. cmdoption:: CPP + + C preprocessor command. + +.. cmdoption:: CPPFLAGS + + C preprocessor flags, e.g. ``-I``. + +.. cmdoption:: CURSES_CFLAGS +.. cmdoption:: CURSES_LIBS + + C compiler and linker flags for ``libncurses`` or ``libncursesw``, used by + :mod:`curses` module, overriding ``pkg-config``. + +.. cmdoption:: GDBM_CFLAGS +.. cmdoption:: GDBM_LIBS + + C compiler and linker flags for ``gdbm``. + +.. cmdoption:: HOSTRUNNER + + Program to run CPython for the host platform for cross-compilation. + +.. cmdoption:: LDFLAGS + + Linker flags, e.g. ``-L``. + + See also :option:`LIBS`. + +.. cmdoption:: LIBATOMIC + + Linker flags when ``cpython/pyatomic.h`` header file is used. + + Default: ``LIBATOMIC='-latomic'`` if ``libatomic`` is needed, or + ``LIBATOMIC=''`` otherwise (also the default when Python is cross-compiled). + + .. versionadded:: 3.13 + +.. cmdoption:: LIBB2_CFLAGS +.. cmdoption:: LIBB2_LIBS + + C compiler and linker flags for ``libb2`` (:ref:`BLAKE2 `), + used by :mod:`hashlib` module, overriding ``pkg-config``. + +.. cmdoption:: LIBEDIT_CFLAGS +.. cmdoption:: LIBEDIT_LIBS + + C compiler and linker flags for ``libedit``, used by :mod:`readline` module, + overriding ``pkg-config``. + +.. cmdoption:: LIBFFI_CFLAGS +.. cmdoption:: LIBFFI_LIBS + + C compiler and linker flags for ``libffi``, used by :mod:`ctypes` module, + overriding ``pkg-config``. + +.. cmdoption:: LIBLZMA_CFLAGS +.. cmdoption:: LIBLZMA_LIBS + + C compiler and linker flags for ``liblzma``, used by :mod:`lzma` module, + overriding ``pkg-config``. + +.. cmdoption:: LIBREADLINE_CFLAGS +.. cmdoption:: LIBREADLINE_LIBS + + C compiler and linker flags for ``libreadline``, used by :mod:`readline` + module, overriding ``pkg-config``. + +.. cmdoption:: LIBS + + Libraries to pass to the linker, e.g. ``-l``. + + See also :option:`LDFLAGS`. + +.. cmdoption:: LIBSQLITE3_CFLAGS +.. cmdoption:: LIBSQLITE3_LIBS + + C compiler and linker flags for ``libsqlite3``, used by :mod:`sqlite3` + module, overriding ``pkg-config``. + +.. cmdoption:: LIBUUID_CFLAGS +.. cmdoption:: LIBUUID_LIBS + + C compiler and linker flags for ``liuuid``, used by :mod:`uuid` module, + overriding ``pkg-config``. + +.. cmdoption:: MACHDEP + + Name for machine-dependent library files. + +.. cmdoption:: PANEL_CFLAGS +.. cmdoption:: PANEL_LIBS + + C compiler and Linker flags for PANEL, overriding ``pkg-config``. + + C compiler and linker flags for ``libpanel`` or ``libpanelw``, used by + :mod:`curses.panel` module, overriding ``pkg-config``. + +.. cmdoption:: PKG_CONFIG + + Path to ``pkg-config`` utility. + +.. cmdoption:: PKG_CONFIG_LIBDIR +.. cmdoption:: PKG_CONFIG_PATH +.. cmdoption:: PROFILE_TASK + + Python command line arguments for PGO generation task. + + Default: ``PROFILE_TASK='-m test --pgo --timeout=$(TESTTIMEOUT)'``. + +.. cmdoption:: TCLTK_CFLAGS +.. cmdoption:: TCLTK_LIBS + + C compiler and linker flags for TCLTK, overriding ``pkg-config``. + +.. cmdoption:: ZLIB_CFLAGS +.. cmdoption:: ZLIB_LIBS + + C compiler and linker flags for ``libzlib``, used by :mod:`gzip` module, + overriding ``pkg-config``. + + General Options --------------- @@ -750,6 +898,8 @@ for another CPU architecture or platform. Cross compiling requires a Python interpreter for the build platform. The version of the build Python must match the version of the cross compiled host Python. +See also :option:`HOSTRUNNER`. + .. cmdoption:: --build=BUILD configure for building on BUILD, usually guessed by :program:`config.guess`.