build: force migration away from $(AR)
authorMike Frysinger <vapier@gentoo.org>
Wed, 12 Oct 2011 19:25:20 +0000 (19:25 +0000)
committerWolfgang Denk <wd@denx.de>
Fri, 21 Oct 2011 23:19:28 +0000 (01:19 +0200)
People keep adding new code that still uses $(AR) instead of
$(cmd_link_o_target), so turn it into a build time error.

We still use $(AR) locally, but we don't use $(ARFLAGS).

Signed-off-by: Mike Frysinger <vapier@gentoo.org>
config.mk

index 3fa9eef..bad72b7 100644 (file)
--- a/config.mk
+++ b/config.mk
@@ -157,11 +157,9 @@ endif
 
 #########################################################################
 
-ifneq (,$(findstring s,$(MAKEFLAGS)))
-ARFLAGS = cr
-else
-ARFLAGS = crv
-endif
+# We don't actually use $(ARFLAGS) anywhere anymore, so catch people
+# who are porting old code to latest mainline but not updating $(AR).
+ARFLAGS = $(error update your Makefile to use cmd_link_o_target and not AR)
 RELFLAGS= $(PLATFORM_RELFLAGS)
 DBGFLAGS= -g # -DDEBUG
 OPTFLAGS= -Os #-fomit-frame-pointer