platform_kernel-5.15/Documentation/kbuild
Elliot Berman df70410432 FROMLIST: kbuild: Add environment variables for userprogs flags
Allow additional arguments be passed to userprogs compilation.
Reproducible clang builds need to provide a sysroot and gcc path to
ensure the same toolchain is used across hosts. KCFLAGS is not currently
used for any user programs compilation, so add new USERCFLAGS and
USERLDFLAGS which serves similar purpose as HOSTCFLAGS/HOSTLDFLAGS.

Clang 13+ might detect GCC installation on hosts which have it installed
to a default location in /. With addition of these environment
variables, you can specify flags such as:

$ make USERCFLAGS=--sysroot=/path/to/sysroot

This can also be used to specify different sysroots such as musl or
bionic which may be installed on the host in paths that the compiler
may not search by default.

Signed-off-by: Elliot Berman <quic_eberman@quicinc.com>
Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Bug: 214127735
Link: https://lore.kernel.org/linux-kbuild/20220201213542.2808035-1-quic_eberman@quicinc.com/
Change-Id: I035309a569130774a1212f294973eee2830a6588
2022-02-07 18:07:42 +00:00
..
Kconfig.recursion-issue-01 kbuild: document recursive dependency limitation / resolution 2015-10-08 15:36:16 +02:00
Kconfig.recursion-issue-02 docs: kbuild: Fix a typo in the file Kconfig.recursion-issue-02 2021-04-25 05:13:56 +09:00
Kconfig.select-break kbuild: document recursive dependency limitation / resolution 2015-10-08 15:36:16 +02:00
gcc-plugins.rst doc: gcc-plugins: update gcc-plugins.rst 2021-01-26 06:23:20 +09:00
headers_install.rst Kbuild updates for v5.3 2019-07-12 16:03:16 -07:00
index.rst Kbuild updates for v5.7 2020-03-31 16:03:39 -07:00
issues.rst docs: kbuild: fix build with pdf and fix some minor issues 2019-07-15 11:03:04 -03:00
kbuild.rst FROMLIST: kbuild: Add environment variables for userprogs flags 2022-02-07 18:07:42 +00:00
kconfig-language.rst kconfig: change "modules" from sub-option to first-level attribute 2021-04-14 15:22:49 +09:00
kconfig-macro-language.rst kconfig: doc: fix $(fileno) to $(filename) 2020-12-21 16:01:44 +09:00
kconfig.rst kconfig: change defconfig_list option to environment variable 2021-04-14 15:22:48 +09:00
llvm.rst Merge branch 'akpm' (patches from Andrew) 2021-09-08 12:55:35 -07:00
makefiles.rst FROMLIST: kbuild: Add environment variables for userprogs flags 2022-02-07 18:07:42 +00:00
modules.rst Merge 7b95f0563a ("Merge tag 'kbuild-v5.11' of git://git.kernel.org/pub/scm/linux/kernel/git/masahiroy/linux-kbuild") into android-mainline 2021-01-13 11:32:21 +01:00
reproducible-builds.rst gcc-plugins: fix gcc-plugins directory path in documentation 2020-06-28 12:16:55 +09:00