powerpc: fix boot_rom.bin build
My powerpc objcopy (version 2.23.52.20130305) did a seek() that bash process substitution couldn't handle! I've changed the Makefile to do things the old fashioned way.
--- powerpc/Makefile.common | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
powerpc/Makefile.common +2 -1
@@ -48,7 +48,8 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@ $(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.o
Signature · 1 line
2.7.0.rc3.207.g0ac5344
Andrew Jones
Reviewed-byQuoted 25 lines · Peter Feiner
My powerpc objcopy (version 2.23.52.20130305) did a
seek()that bash process substitution couldn't handle! I've changed theMakefileto do things the old fashioned way.Signed-off-by Peter Feiner <[email protected]>--- powerpc/Makefile.common | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)powerpc/Makefile.common +2
-1@@ -48,7 +48,8 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@ $(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.oSignature · 1 line
2.7.0.rc3.207.g0ac5344
Quoted 22 lines · Andrew Jones
Quoted 21 lines · Peter Feiner
My powerpc objcopy (version 2.23.52.20130305) did a
seek()that bash process substitution couldn't handle! I've changed theMakefileto do things the old fashioned way.Signed-off-by Peter Feiner <[email protected]>--- powerpc/Makefile.common | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)powerpc/Makefile.common +2
-1@@ -48,7 +48,8 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@
Quoted 6 lines
Quoted 4 lines
powerpc/Makefile.common +0
-0$(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.oSignature · 1 line
2.7.0.rc3.207.g0ac5344Reviewed-by Andrew Jones <[email protected]>
Actually, Unreviewed-by: drew
This leaves boot_rom.bin.suffix laying around. We need rm -f [email protected] too. And, why '.suffix'? How about '.tmp', or even use a tempfile?
Thanks,
drew
Quoted 4 lines
--
To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 30 lines · Andrew Jones
Quoted 22 lines · Andrew Jones
Quoted 21 lines · Peter Feiner
My powerpc objcopy (version 2.23.52.20130305) did a
seek()that bash process substitution couldn't handle! I've changed theMakefileto do things the old fashioned way.Signed-off-by Peter Feiner <[email protected]>--- powerpc/Makefile.common | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)powerpc/Makefile.common +2
-1@@ -48,7 +48,8 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@Quoted 6 lines
Quoted 4 lines
powerpc/Makefile.common +0
-1$(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.o --2.7.0.rc3.207.g0ac5344
Reviewed-by Andrew Jones <[email protected]>
Quoted 4 lines
Actually, Unreviewed-by: drew
This leaves boot_rom.bin.suffix laying around. We need rm -f [email protected] too. And, why '.suffix'? How about '.tmp', or even use a tempfile?
.suffix because it's the end of the file.
I don't think tempfile is necessary because, in general, a Makefile has first refusal on the files in a directory. If you create a boot_rom.bin.suffix and make overwrites it, it's your problem!
I'll add the rm -f.
PATCH v2 1/1 powerpc: fix boot_rom.bin build
In reply to Peter FeinerMy powerpc objcopy (version 2.23.52.20130305) did a seek() that bash process substitution couldn't handle! I've changed the Makefile to do things the old fashioned way.
---
v2:
* rm the temporary file
* renamed temporary file to .tmp instead of .suffix
--- powerpc/Makefile.common | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)
powerpc/Makefile.common +3 -1
@@ -48,7 +48,9 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@ + $(RM) [email protected] $(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.o
Signature · 1 line
2.7.0.rc3.207.g0ac5344
Quoted 5 lines · Peter Feiner
My powerpc objcopy (version 2.23.52.20130305) did a
seek()that bash process substitution couldn't handle! I've changed theMakefileto do things the old fashioned way.Signed-off-by Peter Feiner <[email protected]>
Thanks for the v2!
drew
Quoted 32 lines
---
v2:
* rm the temporary file
* renamed temporary file to .tmp instead of .suffix--- powerpc/Makefile.common | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)powerpc/Makefile.common +3
-1@@ -48,7 +48,9 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@ + $(RM) [email protected] $(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.oSignature · 6 lines
2.7.0.rc3.207.g0ac5344 -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to [email protected] More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 21 lines · Peter Feiner
My powerpc objcopy (version 2.23.52.20130305) did a
seek()that bash process substitution couldn't handle! I've changed theMakefileto do things the old fashioned way.Signed-off-by Peter Feiner <[email protected]>---
v2:
* rm the temporary file
* renamed temporary file to .tmp instead of .suffix--- powerpc/Makefile.common | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)powerpc/Makefile.common +0
-0
powerpc/Makefile.common FLATLIBS = $(libcflat) $(LIBFDT_archive) · line 56
Quoted 10 lines
powerpc/Makefile.common +3
-1@@ -48,7 +48,9 @@ FLATLIBS = $(libcflat) $(LIBFDT_archive) $(TEST_DIR)/boot_rom.bin: $(TEST_DIR)/boot_rom.elf dd if=/dev/zero of=$@ bs=256 count=1 - $(OBJCOPY) -O binary $^ >(cat - >>$@) + $(OBJCOPY) -O binary $^ [email protected] + cat [email protected] >> $@ + $(RM) [email protected] $(TEST_DIR)/boot_rom.elf: CFLAGS = -mbig-endian $(TEST_DIR)/boot_rom.elf: $(TEST_DIR)/boot_rom.o
Applied, thanks.
Paolo