Skip to contentSkip to conversation

kbuild: warn if always, hostprogs-y, or hostprogs-m is used

PATCH New Masahiro Yamada 1 participant 1 message Apr 27, 2020 Kbuild

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 kbuild: warn if always, hostprogs-y, or hostprogs-m is used

always, hostprogs-y, and hostprogs-m are deprecated.

There is no user in upstream code, but I am keeping them for external modules. I want to remove them entirely someday. Notify the deprecation to downstream users.

---

 scripts/Makefile.lib | 6 ++++++
 1 file changed, 6 insertions(+)
scripts/Makefile.lib +6 -0
index cd52a8c6428f..f869a4b2646c 100644
@@ -4,8 +4,14 @@ asflags-y  += $(EXTRA_AFLAGS)
 ccflags-y  += $(EXTRA_CFLAGS)
 cppflags-y += $(EXTRA_CPPFLAGS)
 ldflags-y  += $(EXTRA_LDFLAGS)
+ifneq ($(always),)
+$(warning 'always' is deprecated. Please use 'always-y' instead)
 always-y   += $(always)
+endif
+ifneq ($(hostprogs-y)$(hostprogs-m),)
+$(warning 'hostprogs-y' and 'hostprogs-m' are deprecated. Please use 'hostprogs' instead)
 hostprogs  += $(hostprogs-y) $(hostprogs-m)
+endif
 
 # flags that take effect in current and sub directories
 KBUILD_AFLAGS += $(subdir-asflags-y)
Signature · 1 line
2.25.1