Document more package-specific envvars [no ci]

This commit is contained in:
Ivan Pozdeev 2024-12-13 22:59:53 +03:00
parent d6a00fb6fd
commit 3e24e22a57

View File

@ -169,16 +169,14 @@ You can set certain environment variables to control the build process.
* `PYTHON_BUILD_DEFINITIONS` can be a list of colon-separated paths that get * `PYTHON_BUILD_DEFINITIONS` can be a list of colon-separated paths that get
additionally searched when looking up build definitions. additionally searched when looking up build definitions.
* `CC` sets the path to the C compiler. * `CC` sets the path to the C compiler.
* `PYTHON_CFLAGS` lets you pass additional options to the default `CFLAGS`. Use
this to override, for instance, the `-O3` option.
* `CONFIGURE_OPTS` lets you pass additional options to `./configure`. * `CONFIGURE_OPTS` lets you pass additional options to `./configure`.
* `MAKE` lets you override the command to use for `make`. Useful for specifying * `MAKE` lets you override the command to use for `make`. Useful for specifying
GNU make (`gmake`) on some systems. GNU make (`gmake`) on some systems.
* `MAKE_OPTS` (or `MAKEOPTS`) lets you pass additional options to `make`. * `MAKE_OPTS` (or `MAKEOPTS`) lets you pass additional options to `make`.
* `MAKE_INSTALL_OPTS` lets you pass additional options to `make install`. * `MAKE_INSTALL_OPTS` lets you pass additional options to `make install`.
* `PYTHON_CONFIGURE_OPTS` and `PYTHON_MAKE_OPTS` and `PYTHON_MAKE_INSTALL_OPTS` allow * `<PACKAGE>_CFLAGS`, `<PACKAGE>_CPPFLAGS`, `<PACKAGE>_LDFLAGS` lets you pass additional options to `CFLAGS`/`CPPFLAGS`/`LDFLAGS` specifically for building `<package>` (Python itself or a dependency library) from source as part of the build script. `<PACKAGE>` should be a capitalized name of the package without version (technically, capitalized first argument to `install_package` without version). E.g. for CPython, it's "`PYTHON`", for Readline, "`READLINE`", for PyPy (only applies when building it from source), "`PYPY`". Check the source of the build script you're using if unsure.
you to specify configure and make options for building CPython. These variables * `<PACKAGE>_CONFIGURE_OPTS`, `<PACKAGE>_MAKE_OPTS`, `<PACKAGE>_MAKE_INSTALL_OPTS`, `<PACKAGE>_MAKE_INSTALL_TARGET` allow
will be passed to Python only, not any dependent packages (e.g. libyaml). you to specify configure and make options for building `<package>` (same as above). "Make install target" would replace "`install`" in the `make install` invocation.
### Applying patches to Python before compiling ### Applying patches to Python before compiling