diff options
author | Paul Smith <psmith@gnu.org> | 2006-03-05 17:14:10 -0500 |
---|---|---|
committer | Sam Ravnborg <sam@mars.ravnborg.org> | 2006-03-05 18:09:51 -0500 |
commit | 4f1933620f57145212cdbb1ac6ce099eeeb21c5a (patch) | |
tree | c083cce1f0acedd92be2ac6eb5e6c49ebd84ac46 /arch/ppc/boot/openfirmware/Makefile | |
parent | 7b75b13cda8bd21e8636ea985f76e1ce5bd1a470 (diff) |
kbuild: change kbuild to not rely on incorrect GNU make behavior
The kbuild system takes advantage of an incorrect behavior in GNU make.
Once this behavior is fixed, all files in the kernel rebuild every time,
even if nothing has changed. This patch ensures kbuild works with both
the incorrect and correct behaviors of GNU make.
For more details on the incorrect behavior, see:
http://lists.gnu.org/archive/html/bug-make/2006-03/msg00003.html
Changes in this patch:
- Keep all targets that are to be marked .PHONY in a variable, PHONY.
- Add .PHONY: $(PHONY) to mark them properly.
- Remove any $(PHONY) files from the $? list when determining whether
targets are up-to-date or not.
Signed-off-by: Paul Smith <psmith@gnu.org>
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Diffstat (limited to 'arch/ppc/boot/openfirmware/Makefile')
-rw-r--r-- | arch/ppc/boot/openfirmware/Makefile | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/arch/ppc/boot/openfirmware/Makefile b/arch/ppc/boot/openfirmware/Makefile index 2a411ec2e650..66b739743759 100644 --- a/arch/ppc/boot/openfirmware/Makefile +++ b/arch/ppc/boot/openfirmware/Makefile | |||
@@ -1,5 +1,8 @@ | |||
1 | # Makefile for making bootable images on various OpenFirmware machines. | 1 | # Makefile for making bootable images on various OpenFirmware machines. |
2 | # | 2 | # |
3 | # This file is included by the global makefile so that you can add your own | ||
4 | # architecture-specific flags and dependencies. | ||
5 | # | ||
3 | # Paul Mackerras January 1997 | 6 | # Paul Mackerras January 1997 |
4 | # XCOFF bootable images for PowerMacs | 7 | # XCOFF bootable images for PowerMacs |
5 | # Geert Uytterhoeven September 1997 | 8 | # Geert Uytterhoeven September 1997 |
@@ -86,7 +89,7 @@ $(images)/zImage.chrp-rs6k $(images)/zImage.initrd.chrp-rs6k: \ | |||
86 | 89 | ||
87 | # The targets used on the make command-line | 90 | # The targets used on the make command-line |
88 | 91 | ||
89 | .PHONY: zImage zImage.initrd | 92 | PHONY += zImage zImage.initrd |
90 | zImage: $(images)/zImage.chrp \ | 93 | zImage: $(images)/zImage.chrp \ |
91 | $(images)/zImage.chrp-rs6k | 94 | $(images)/zImage.chrp-rs6k |
92 | @echo ' kernel: $@ is ready ($<)' | 95 | @echo ' kernel: $@ is ready ($<)' |
@@ -96,7 +99,7 @@ zImage.initrd: $(images)/zImage.initrd.chrp \ | |||
96 | 99 | ||
97 | TFTPIMAGE := /tftpboot/zImage | 100 | TFTPIMAGE := /tftpboot/zImage |
98 | 101 | ||
99 | .PHONY: znetboot znetboot.initrd | 102 | PHONY += znetboot znetboot.initrd |
100 | znetboot: $(images)/zImage.chrp | 103 | znetboot: $(images)/zImage.chrp |
101 | cp $(images)/zImage.chrp $(TFTPIMAGE).chrp$(END) | 104 | cp $(images)/zImage.chrp $(TFTPIMAGE).chrp$(END) |
102 | @echo ' kernel: $@ is ready ($<)' | 105 | @echo ' kernel: $@ is ready ($<)' |