Buildroot Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCH] Makefile: make printvars target print all variables if no VARS set
@ 2022-08-01 13:30 Quentin Schulz
  2022-08-01 15:12 ` Yann E. MORIN
  0 siblings, 1 reply; 4+ messages in thread
From: Quentin Schulz @ 2022-08-01 13:30 UTC (permalink / raw)
  To: buildroot; +Cc: Quentin Schulz, Quentin Schulz

From: Quentin Schulz <quentin.schulz@theobroma-systems.com>

VARS is not defined by default, meaning the filter will not return
anything which ends up making `make printvars` also return nothing.

Fix this by setting VARS to '%' - which is the match-all pattern - in
printvars using a conditional variable assignment operator, such as
what's currently done for show-vars.

Fixes: 5c54c3ef3db2 ("Makefile: workaround make 4.3 issue for 'printvars and 'show-vars'")
Cc: Quentin Schulz <foss+buildroot@0leil.net>
Signed-off-by: Quentin Schulz <quentin.schulz@theobroma-systems.com>
---
 Makefile | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Makefile b/Makefile
index a743e42f91..f1b5494726 100644
--- a/Makefile
+++ b/Makefile
@@ -1057,6 +1057,7 @@ endif
 # Note: we iterate of .VARIABLES and filter each variable individually,
 # to workaround a bug in make 4.3; see https://savannah.gnu.org/bugs/?59093
 .PHONY: printvars
+printvars: VARS?=%
 printvars:
 	@:
 	$(foreach V, \
-- 
2.37.1

_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2022-08-01 16:10 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2022-08-01 13:30 [Buildroot] [PATCH] Makefile: make printvars target print all variables if no VARS set Quentin Schulz
2022-08-01 15:12 ` Yann E. MORIN
2022-08-01 15:15   ` Quentin Schulz
2022-08-01 16:10     ` Yann E. MORIN

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox