* [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile
@ 2010-05-29 11:11 Sam Ravnborg
0 siblings, 0 replies; 7+ messages in thread
From: Sam Ravnborg @ 2010-05-29 11:11 UTC (permalink / raw)
Fix clean-file usage in arch/mips/boot/compressed/Makefile
With this fixed there is no need for CLEAN_FILES
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
---
Noticed this while browsing the mips makefiles.
I have tested this lightly (only with the ar7 platfrom).
Sam
arch/mips/Makefile | 10 ----------
arch/mips/boot/compressed/Makefile | 4 +---
2 files changed, 1 insertions(+), 13 deletions(-)
diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index 92346d0..9a94dee 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -755,9 +755,6 @@ vmlinux.ecoff: $(vmlinux-32)
vmlinux.srec: $(vmlinux-32)
+@$(call makeboot,$@)
-CLEAN_FILES += vmlinux.ecoff \
- vmlinux.srec
-
archprepare:
ifdef CONFIG_MIPS32_N32
@echo ' Checking missing-syscalls for N32'
@@ -792,10 +789,3 @@ define archhelp
echo ' These will be default as apropriate for a configured platform.'
endef
-CLEAN_FILES += vmlinux.32 \
- vmlinux.64 \
- vmlinux.ecoff \
- vmlinuz \
- vmlinuz.ecoff \
- vmlinuz.bin \
- vmlinuz.srec
diff --git a/arch/mips/boot/compressed/Makefile b/arch/mips/boot/compressed/Makefile
index 790ddd3..80f6de5 100644
--- a/arch/mips/boot/compressed/Makefile
+++ b/arch/mips/boot/compressed/Makefile
@@ -100,6 +100,4 @@ OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec
vmlinuz.srec: vmlinuz
$(call if_changed,objcopy)
-clean:
-clean-files += *.o \
- vmlinu*
+clean-files := $(objtree)/vmlinu*
--
1.6.0.6
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile
@ 2010-05-29 11:11 Sam Ravnborg
0 siblings, 0 replies; 7+ messages in thread
From: Sam Ravnborg @ 2010-05-29 11:11 UTC (permalink / raw)
Fix clean-file usage in arch/mips/boot/compressed/Makefile
With this fixed there is no need for CLEAN_FILES
Update clean-files in arch/mips/boot/Makefile so
it only list relevant files.
Include fix from Wu Zhangjin so we do not miss any
files in arch/mips/boot/compressed
Signed-off-by: Sam Ravnborg <sam@ravnborg.org>
Cc: Wu Zhangjin <wuzhangjin@gmail.com>
---
Hi Wu - thanks for spotting this bug!
Updated patch below.
Sam
arch/mips/Makefile | 10 ----------
arch/mips/boot/Makefile | 5 +----
arch/mips/boot/compressed/Makefile | 7 ++++---
3 files changed, 5 insertions(+), 17 deletions(-)
diff --git a/arch/mips/Makefile b/arch/mips/Makefile
index 92346d0..9a94dee 100644
--- a/arch/mips/Makefile
+++ b/arch/mips/Makefile
@@ -755,9 +755,6 @@ vmlinux.ecoff: $(vmlinux-32)
vmlinux.srec: $(vmlinux-32)
+@$(call makeboot,$@)
-CLEAN_FILES += vmlinux.ecoff \
- vmlinux.srec
-
archprepare:
ifdef CONFIG_MIPS32_N32
@echo ' Checking missing-syscalls for N32'
@@ -792,10 +789,3 @@ define archhelp
echo ' These will be default as apropriate for a configured platform.'
endef
-CLEAN_FILES += vmlinux.32 \
- vmlinux.64 \
- vmlinux.ecoff \
- vmlinuz \
- vmlinuz.ecoff \
- vmlinuz.bin \
- vmlinuz.srec
diff --git a/arch/mips/boot/Makefile b/arch/mips/boot/Makefile
index e39a08e..de20e81 100644
--- a/arch/mips/boot/Makefile
+++ b/arch/mips/boot/Makefile
@@ -39,7 +39,4 @@ vmlinux.bin: $(VMLINUX)
vmlinux.srec: $(VMLINUX)
$(OBJCOPY) -S -O srec $(strip-flags) $(VMLINUX) $(obj)/vmlinux.srec
-clean-files += elf2ecoff \
- vmlinux.bin \
- vmlinux.ecoff \
- vmlinux.srec
+clean-files += elf2ecoff
diff --git a/arch/mips/boot/compressed/Makefile b/arch/mips/boot/compressed/Makefile
index 790ddd3..223dd4d 100644
--- a/arch/mips/boot/compressed/Makefile
+++ b/arch/mips/boot/compressed/Makefile
@@ -100,6 +100,7 @@ OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec
vmlinuz.srec: vmlinuz
$(call if_changed,objcopy)
-clean:
-clean-files += *.o \
- vmlinu*
+# vmlinu* files created in top-level dir of the kernel
+clean-files := $(objtree)/vmlinu*
+# files created in arch/mips/boot/compressed
+clean-files += vmlinux.* piggy.o
--
1.6.0.6
^ permalink raw reply related [flat|nested] 7+ messages in thread
* [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile
@ 2010-05-29 11:17 Sam Ravnborg
2010-05-29 12:06 ` Wu Zhangjin
0 siblings, 1 reply; 7+ messages in thread
From: Sam Ravnborg @ 2010-05-29 11:17 UTC (permalink / raw)
To: Ralf Baechle, linux-mips
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile
2010-05-29 11:17 [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile Sam Ravnborg
@ 2010-05-29 12:06 ` Wu Zhangjin
2010-05-29 19:40 ` [PATCHv2] " Sam Ravnborg
0 siblings, 1 reply; 7+ messages in thread
From: Wu Zhangjin @ 2010-05-29 12:06 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: Ralf Baechle, linux-mips
Hi, Sam
With your patch, It really drops the specified files in the root
directory of Linux source code but can not remove the files under
arch/mips/boot/compressed/.
I have kept some temp files (.bin, .lzo...) under
arch/mips/boot/compressed/,
> diff --git a/arch/mips/boot/compressed/Makefile b/arch/mips/boot/compressed/Makefile
> index 790ddd3..80f6de5 100644
> --- a/arch/mips/boot/compressed/Makefile
> +++ b/arch/mips/boot/compressed/Makefile
> @@ -100,6 +100,4 @@ OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec
> vmlinuz.srec: vmlinuz
> $(call if_changed,objcopy)
>
> -clean:
> -clean-files += *.o \
> - vmlinu*
> +clean-files := $(objtree)/vmlinu*
So, perhaps we need to reserve the vmlinux*, then we get
+ clean-files := vmlinu* \
$(objtree)/vmlinu*
Best Regards,
Wu Zhangjin
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCHv2] mips: drop CLEAN_FILES from arch/mips/Makefile
2010-05-29 12:06 ` Wu Zhangjin
@ 2010-05-29 19:40 ` Sam Ravnborg
2010-05-29 19:40 ` Sam Ravnborg
2010-05-30 3:00 ` Wu Zhangjin
0 siblings, 2 replies; 7+ messages in thread
From: Sam Ravnborg @ 2010-05-29 19:40 UTC (permalink / raw)
To: Wu Zhangjin, Ralf Baechle; +Cc: Ralf Baechle, linux-mips
^ permalink raw reply [flat|nested] 7+ messages in thread
* [PATCHv2] mips: drop CLEAN_FILES from arch/mips/Makefile
2010-05-29 19:40 ` [PATCHv2] " Sam Ravnborg
@ 2010-05-29 19:40 ` Sam Ravnborg
2010-05-30 3:00 ` Wu Zhangjin
1 sibling, 0 replies; 7+ messages in thread
From: Sam Ravnborg @ 2010-05-29 19:40 UTC (permalink / raw)
To: Wu Zhangjin, Ralf Baechle; +Cc: linux-mips
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [PATCHv2] mips: drop CLEAN_FILES from arch/mips/Makefile
2010-05-29 19:40 ` [PATCHv2] " Sam Ravnborg
2010-05-29 19:40 ` Sam Ravnborg
@ 2010-05-30 3:00 ` Wu Zhangjin
1 sibling, 0 replies; 7+ messages in thread
From: Wu Zhangjin @ 2010-05-30 3:00 UTC (permalink / raw)
To: Sam Ravnborg; +Cc: Ralf Baechle, linux-mips
Hi, Sam
Most of them looks good, thanks!
[...]
> diff --git a/arch/mips/boot/compressed/Makefile b/arch/mips/boot/compressed/Makefile
> index 790ddd3..223dd4d 100644
> --- a/arch/mips/boot/compressed/Makefile
> +++ b/arch/mips/boot/compressed/Makefile
> @@ -100,6 +100,7 @@ OBJCOPYFLAGS_vmlinuz.srec := $(OBJCOPYFLAGS) -S -O srec
> vmlinuz.srec: vmlinuz
> $(call if_changed,objcopy)
>
> -clean:
> -clean-files += *.o \
> - vmlinu*
> +# vmlinu* files created in top-level dir of the kernel
> +clean-files := $(objtree)/vmlinu*
> +# files created in arch/mips/boot/compressed
> +clean-files += vmlinux.* piggy.o
but just tested it, seems the above piggy.o is not needed.
Thanks & Regards,
Wu Zhangjin
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2010-05-30 3:01 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-05-29 11:17 [PATCH] mips: drop CLEAN_FILES from arch/mips/Makefile Sam Ravnborg
2010-05-29 12:06 ` Wu Zhangjin
2010-05-29 19:40 ` [PATCHv2] " Sam Ravnborg
2010-05-29 19:40 ` Sam Ravnborg
2010-05-30 3:00 ` Wu Zhangjin
-- strict thread matches above, loose matches on Subject: below --
2010-05-29 11:11 [PATCH] " Sam Ravnborg
2010-05-29 11:11 Sam Ravnborg
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).