selftests/nolibc: support out-of-tree builds
authorThomas Weißschuh <linux@weissschuh.net>
Tue, 31 Oct 2023 20:37:00 +0000 (21:37 +0100)
committerThomas Weißschuh <linux@weissschuh.net>
Mon, 11 Dec 2023 21:38:16 +0000 (22:38 +0100)
commit69620b3a5bc5e6798724ab9bf0dd1b3c980a4949
tree7ffab02ba340ecb9deb6be99a5ca9cd89c8bbbc3
parent7263c9d9b67a9412fcfc2c90b259a28d55d0e970
selftests/nolibc: support out-of-tree builds

Out of tree builds are much more convenient when building for multiple
architectures or configurations in parallel.

Only absolute O= parameters are supported as Makefile.include will
always resolve relative paths in relation to $(srctree) instead of the
current directory.

Add a call to "make outputmakefile" to verify that the sourcetree is
clean.

This is based on Zhangjins out-of-tree patch.
It extends that work for get_init_cpio support and also drops relative
O= specifications explicitly.

Link: https://lore.kernel.org/lkml/06d96bd81fe812a9718098a383678ad3beba98b1.1691215074.git.falcon@tinylab.org/
Co-developed-by: Zhangjin Wu <falcon@tinylab.org>
Signed-off-by: Zhangjin Wu <falcon@tinylab.org>
Signed-off-by: Thomas Weißschuh <linux@weissschuh.net>
Acked-by: Willy Tarreau <w@1wt.eu>
Link: https://lore.kernel.org/r/20231031-nolibc-out-of-tree-v1-3-47c92f73590a@weissschuh.net
tools/testing/selftests/nolibc/Makefile