diff options
author | 2020-11-28 20:51:07 +0900 | |
---|---|---|
committer | 2020-12-21 13:57:07 +0900 | |
commit | d0e628cd817f3b67ad80cceaf527c7bb37c27b1c (patch) | |
tree | 3fd0dc1623c2b077d7c66b7bf62762fa5a2c959f /tools/perf/scripts/python/export-to-postgresql.py | |
parent | kbuild: doc: split if_changed explanation to a separate section (diff) | |
download | linux-dev-d0e628cd817f3b67ad80cceaf527c7bb37c27b1c.tar.xz linux-dev-d0e628cd817f3b67ad80cceaf527c7bb37c27b1c.zip |
kbuild: doc: clarify the difference between extra-y and always-y
The difference between extra-y and always-y is obscure.
Basically, Kbuild builds targets listed in extra-y and always-y in
visited Makefiles without relying on any dependency.
The difference is that extra-y is used to list the targets needed for
vmlinux whereas always-y is used to list the targets that must be always
built irrespective of final targets.
Kbuild skips extra-y when it is building only modules (i.e.
'make modules'). This is the long-standing behavior since extra-y was
introduced in 2003, and it is explained in that commit log [1].
For clarification, this is the extra-y vs always-y table:
extra-y always-y
'make' y y
'make vmlinux' y y
'make modules' n y
Kbuild skips extra-y also when building external modules since obviously
it never builds vmlinux.
Unfortunately, extra-y is wrongly used in many places of upstream code,
and even in external modules.
Using extra-y in external module Makefiles is wrong. What you should
use is probably always-y or 'targets'.
The current documentation for extra-y is misleading. I rewrote it, and
moved it to the section 3.7.
always-y is not documented anywhere. I added.
[1]: https://git.kernel.org/pub/scm/linux/kernel/git/history/history.git/commit/?id=f94e5fd7e5d09a56a60670a9bb211a791654bba8
Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
Reviewed-by: Randy Dunlap <rdunlap@infradead.org>
Diffstat (limited to 'tools/perf/scripts/python/export-to-postgresql.py')
0 files changed, 0 insertions, 0 deletions