]> git.ipfire.org Git - people/ms/u-boot.git/blobdiff - Makefile
spl: Change PAD_TO to CONFIG_SPL_PAD_TO
[people/ms/u-boot.git] / Makefile
index 9d434993cc49caf42bb03f3285b999327fd64601..7e16da94d9a3b4eeefaf0d6b40f1e32c25e91d34 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -485,8 +485,12 @@ $(obj)u-boot.sha1: $(obj)u-boot.bin
 $(obj)u-boot.dis:      $(obj)u-boot
                $(OBJDUMP) -d $< > $@
 
+
+
 $(obj)u-boot-with-spl.bin: $(obj)spl/u-boot-spl.bin $(obj)u-boot.bin
-               $(OBJCOPY) ${OBJCFLAGS} --pad-to=$(PAD_TO) -O binary $(obj)spl/u-boot-spl $(obj)spl/u-boot-spl-pad.bin
+               $(OBJCOPY) ${OBJCFLAGS} --pad-to=$(or $(CONFIG_SPL_PAD_TO),0) \
+                       -O binary $(obj)spl/u-boot-spl \
+                       $(obj)spl/u-boot-spl-pad.bin
                cat $(obj)spl/u-boot-spl-pad.bin $(obj)u-boot.bin > $@
                rm $(obj)spl/u-boot-spl-pad.bin