Merge branch 'master' of git://git.denx.de/u-boot-arm
[glsdk/glsdk-u-boot.git] / Makefile
index 107ee4f909af8c65a4ac738a7ccc7a5d90a9df44..35eee704dd18aed084a06e1b6cc464499ab3a29e 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