@@ -48,14 +48,18 @@ support".
4848Requirements for Optional Modules
4949---------------------------------
5050
51- To build *optional modules * of the standard library, you will need several
52- third-party libraries, along with development dependencies like header files.
53- (In common Linux distributions, development dependencies are found in
54- ``-dev `` or ``-devel `` packages.)
51+ To build :term: `optional modules <optional module> ` of the standard library,
52+ you will need several third-party libraries installed for development
53+ (for example, header files must be available).
5554
56- Missing optional modules are listed near the end of ``make `` output.
57- If you distribute a CPython interpreter without them, it's best practice to
58- advise users, who generally expect that standard library modules are available.
55+ Missing requirements are generally given in ``configure `` output.
56+ Missing optional modules are listed near the end of ``make `` output,
57+ sometimes using an internal name such as ``_ctypes `` for the :mod: `ctypes `
58+ module.
59+
60+ If you distribute a CPython interpreter without optional modules,
61+ it's best practice to advise users, who generally expect that
62+ standard library modules are available.
5963
6064Dependencies to build optional modules are:
6165
@@ -78,23 +82,23 @@ Dependencies to build optional modules are:
7882 * - `liblzma <https://tukaani.org/xz/ >`_
7983 -
8084 - :mod: `lzma `
81- * - `libmpdec <https://www.bytereef.org/mpdecimal/doc/libmpdec/ >`_ [ 4 ]_
85+ * - `libmpdec <https://www.bytereef.org/mpdecimal/doc/libmpdec/ >`_
8286 - 2.5.0
83- - :mod: `decimal `
87+ - :mod: `decimal ` [ 1 ]_
8488 * - `libreadline <https://tiswww.case.edu/php/chet/readline/rltop.html >`_ or
85- `libedit <https://www.thrysoee.dk/editline/ >`_ [1 ]_
89+ `libedit <https://www.thrysoee.dk/editline/ >`_ [2 ]_
8690 -
8791 - :mod: `readline `
8892 * - `libuuid <https://linux.die.net/man/3/libuuid >`_
8993 -
9094 - :mod: `uuid `
91- * - `ncurses <https://gnu.org/software/ncurses/ncurses.html >`_ [2 ]_
95+ * - `ncurses <https://gnu.org/software/ncurses/ncurses.html >`_ [3 ]_
9296 -
9397 - :mod: `curses `
9498 * - `OpenSSL <https://openssl-library.org/ >`_
9599 - | 3.0.18 recommended
96100 | (1.1.1 minimum)
97- - :mod: `ssl `, :mod: `hashlib ` [3 ]_
101+ - :mod: `ssl `, :mod: `hashlib ` [4 ]_
98102 * - `SQLite <https://sqlite.org/ >`_
99103 - 3.15.2
100104 - :mod: `sqlite3 `
@@ -103,22 +107,26 @@ Dependencies to build optional modules are:
103107 - :mod: `tkinter `
104108 * - `zlib <https://www.zlib.net >`_
105109 - 1.2.2.1
106- - :mod: `zlib `, :mod: `ensurepip `
110+ - :mod: `zlib `, :mod: `gzip `, :mod: ` ensurepip `
107111 * - `zstd <https://facebook.github.io/zstd/ >`_
108112 - 1.4.5
109113 - :mod: `compression.zstd `
110114
111- .. [1 ] See :option: `--with-readline ` for choosing the backend for the
115+ .. [1 ] If *libmpdec * is not available, CPython will use a bundled copy.
116+ This is deprecated; see :option: `--with-system-libmpdec ` for details.
117+
118+ .. when the bundled libmpdec is removed, we should instead note that
119+ :mod:`decimal` will fall back to a pure-Python implementation.
120+
121+ .. [2 ] See :option: `--with-readline ` for choosing the backend for the
112122 :mod: `readline ` module.
113- .. [2 ] The :mod: `curses ` module requires the ``libncurses `` or ``libncursesw ``
123+ .. [3 ] The :mod: `curses ` module requires the ``libncurses `` or ``libncursesw ``
114124 library.
115125 The :mod: `curses.panel ` module additionally requires the ``libpanel `` or
116126 ``libpanelw `` library.
117- .. [3 ] If OpenSSL is not available, the :mod: `hashlib ` module will use
127+ .. [4 ] If OpenSSL is not available, the :mod: `hashlib ` module will use
118128 bundled implementations of several hash functions.
119129 See :option: `--with-builtin-hashlib-hashes ` for *forcing * usage of OpenSSL.
120- .. [4 ] If *libmpdec * is not available, CPython will use a bundled copy.
121- This is deprecated; see :option: `--with-system-libmpdec ` for details.
122130
123131 .. seealso ::
124132
@@ -127,6 +135,7 @@ Dependencies to build optional modules are:
127135 instructions on how to install them on common platforms.
128136 * :option: `--with-system-expat ` allows building with an external
129137 `libexpat <https://libexpat.github.io/ >`_ library.
138+ * :ref: `configure-options-for-dependencies `
130139
131140.. versionchanged :: 3.1
132141 Tcl/Tk version 8.3.1 is now required for :mod: `tkinter `.
@@ -467,6 +476,8 @@ Linker options
467476 Name for machine-dependent library files.
468477
469478
479+ .. _configure-options-for-dependencies :
480+
470481Options for third-party dependencies
471482------------------------------------
472483
0 commit comments