Messages in this thread Patches in this message | | | Subject | Re: ftrace scripts and make V=1 | From | Andi Kleen <> | Date | Wed, 05 Aug 2009 10:52:17 +0200 |
| |
Dave Airlie <airlied@gmail.com> writes:
> Hey, > > So I spent 3-4 hrs today (I'm stupid yes) tracking down a .o breakage by > blaming rawhide gcc/binutils as I was using make V=1and seeing only the > compiler chain running, > > However some ftrace script was sneaking in afterwards > and screwing up the .o without mentioning itself. > > Surely V=1 should print all these shitty scripts its running?
I ran into the same problem some time ago and fixed it with these two patches patch.
-Andi
---
kbuild: Fail build if recordmcount.pl fails
When this script fails the build should fail too. Otherwise there are mysterious build failures later.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
--- scripts/Makefile.build | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Index: linux-2.6.31-rc1-ak/scripts/Makefile.build =================================================================== --- linux-2.6.31-rc1-ak.orig/scripts/Makefile.build +++ linux-2.6.31-rc1-ak/scripts/Makefile.build @@ -206,7 +206,7 @@ cmd_modversions = \ endif ifdef CONFIG_FTRACE_MCOUNT_RECORD -cmd_record_mcount = perl $(srctree)/scripts/recordmcount.pl "$(ARCH)" \ +cmd_record_mcount = set -e ; perl $(srctree)/scripts/recordmcount.pl "$(ARCH)" \ "$(if $(CONFIG_64BIT),64,32)" \ "$(OBJDUMP)" "$(OBJCOPY)" "$(CC)" "$(LD)" "$(NM)" "$(RM)" "$(MV)" \ "$(if $(part-of-module),1,0)" "$(@)";
--- kbuild: Echo the record_mcount command
I had some problems with record_mcount in the Makefile and it was hard to track down. Echo it by default to make it easier to diagnose.
Signed-off-by: Andi Kleen <ak@linux.intel.com>
--- scripts/Makefile.build | 1 + 1 file changed, 1 insertion(+) Index: linux-2.6.31-rc1-ak/scripts/Makefile.build =================================================================== --- linux-2.6.31-rc1-ak.orig/scripts/Makefile.build +++ linux-2.6.31-rc1-ak/scripts/Makefile.build @@ -216,6 +216,7 @@ define rule_cc_o_c $(call echo-cmd,checksrc) $(cmd_checksrc) \ $(call echo-cmd,cc_o_c) $(cmd_cc_o_c); \ $(cmd_modversions) \ + $(call echo-cmd,record_mcount) \ $(cmd_record_mcount) \ scripts/basic/fixdep $(depfile) $@ '$(call make-cmd,cc_o_c)' > \ $(dot-target).tmp; \
-- ak@linux.intel.com -- Speaking for myself only.
| |