]> git.kernelconcepts.de Git - karo-tx-uboot.git/blobdiff - config.mk
Switch from archive libraries to partial linking
[karo-tx-uboot.git] / config.mk
index ce8e5f2dff510799c2db8c50548a320af8e88c49..19e0a6e421713218cb8bd47858a9eaabca2506ad 100644 (file)
--- a/config.mk
+++ b/config.mk
@@ -259,3 +259,10 @@ $(obj)%.s: %.c
                -o $@ $< -c -S
 
 #########################################################################
+
+# If the list of objects to link is empty, just create an empty built-in.o
+cmd_link_o_target = $(if $(strip $1),\
+                      $(LD) -r -o $@ $1 ,\
+                      rm -f $@; $(AR) rcs $@ )
+
+#########################################################################