Commit 5bbf93a1 authored by Paul Mackerras's avatar Paul Mackerras

PPC32: Further makefile updates from Sam Ravnborg.

parent c23e30be
This diff is collapsed.
...@@ -45,7 +45,7 @@ zImage.initrd: initrd := .initrd ...@@ -45,7 +45,7 @@ zImage.initrd: initrd := .initrd
zImage.initrd: $(images)/zImage.initrd.prep zImage.initrd: $(images)/zImage.initrd.prep
@echo ' kernel: $@ is ready ($<)' @echo ' kernel: $@ is ready ($<)'
mages)/ramdisk.image.gz: $(images)/ramdisk.image.gz:
@echo ' MISSING $@' @echo ' MISSING $@'
@echo ' RAM disk image must be provided separatly' @echo ' RAM disk image must be provided separatly'
@/bin/false @/bin/false
...@@ -68,20 +68,28 @@ $(obj)/image.initrd.o: $(obj)/dummy.o $(images)/vmlinux.gz $(images)/ramdisk.ima ...@@ -68,20 +68,28 @@ $(obj)/image.initrd.o: $(obj)/dummy.o $(images)/vmlinux.gz $(images)/ramdisk.ima
LDFLAGS_zImage.bin := -Ttext 0x00800000 -Bstatic -T LDFLAGS_zImage.bin := -Ttext 0x00800000 -Bstatic -T
LDFLAGS_zImage.initrd.bin := -Ttext 0x00800000 -Bstatic -T LDFLAGS_zImage.initrd.bin := -Ttext 0x00800000 -Bstatic -T
targets += zImage.bin zImage.initrd.bin targets += zImage.bin
$(obj)/zImage$(initrd).bin: $(boot)/ld.script $(OBJS) $(obj)/image.o $(LIBS) $(obj)/zImage.bin: $(boot)/ld.script $(OBJS) $(obj)/image.o $(LIBS)
$(call if_changed,ld)
targets += zImage.initrd.bin
$(obj)/zImage.initrd.bin: $(boot)/ld.script $(OBJS) $(obj)/image.initrd.o $(LIBS)
$(call if_changed,ld) $(call if_changed,ld)
OBJCOPYFLAGS_zImage := -R .comment -R .stab -R .stabstr OBJCOPYFLAGS_zImage := -R .comment -R .stab -R .stabstr
OBJCOPYFLAGS_zImage.initrd := -R .comment -R .stab -R .stabstr OBJCOPYFLAGS_zImage.initrd := -R .comment -R .stab -R .stabstr
targets += zImage zImage.initrd targets += zImage
$(obj)/zImage$(initrd): %: %.bin FORCE $(obj)/zImage: %: %.bin FORCE
$(call if_changed,objcopy)
targets += zImage.initrd
$(obj)/zImage.initrd: %: %.bin FORCE
$(call if_changed,objcopy) $(call if_changed,objcopy)
quiet_cmd_mkprep = MKPREP $@ quiet_cmd_mkprep = MKPREP $@
cmd_mkprep = $(utils)/mkprep -pbp $< $@ cmd_mkprep = $(utils)/mkprep -pbp $< $@
$(images)/zImage$(initrd).prep: $(obj)/zImage$(initrd) $(utils)/mkprep FORCE $(images)/zImage.prep: $(obj)/zImage $(utils)/mkprep
$(call cmd,mkprep)
$(images)/zImage.initrd.prep: $(obj)/zImage.initrd $(utils)/mkprep
$(call cmd,mkprep) $(call cmd,mkprep)
# #
...@@ -90,5 +98,11 @@ $(images)/zImage$(initrd).prep: $(obj)/zImage$(initrd) $(utils)/mkprep FORCE ...@@ -90,5 +98,11 @@ $(images)/zImage$(initrd).prep: $(obj)/zImage$(initrd) $(utils)/mkprep FORCE
floppy: zImage floppy: zImage
dd if=$(images)/zImage.prep of=/dev/fd0H1440 bs=64b dd if=$(images)/zImage.prep of=/dev/fd0H1440 bs=64b
znetboot.initrd : zImage$(initrd) znetboot : zImage
cp $(images)/zImage$(initrd).prep $(TFTPIMAGE) cp $(images)/zImage.prep $(TFTPIMAGE)
@echo ' kernel: $@ is ready ($<)'
znetboot.initrd : zImage.initrd
cp $(images)/zImage.initrd.prep $(TFTPIMAGE)
@echo ' kernel: $@ is ready ($<)'
...@@ -160,8 +160,7 @@ MKBUGBOOT := $(utils)/mkbugboot ...@@ -160,8 +160,7 @@ MKBUGBOOT := $(utils)/mkbugboot
MKPREP := $(utils)/mkprep MKPREP := $(utils)/mkprep
MKTREE := $(utils)/mktree MKTREE := $(utils)/mktree
$(obj)/dummy.o: $(common)/dummy.c targets := dummy.o
$(CC) -c -o $@ $(common)/dummy.c
$(obj)/zvmlinux: $(OBJS) $(LIBS) $(boot)/ld.script $(images)/vmlinux.gz \ $(obj)/zvmlinux: $(OBJS) $(LIBS) $(boot)/ld.script $(images)/vmlinux.gz \
$(obj)/dummy.o $(obj)/dummy.o
......
int main(void)
{
return 0;
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment