* [PATCH] Makefile: fix up CROSS_COMPILE and READABLE_ASM interaction.
@ 2012-06-18 4:55 Paul Mundt
2012-06-19 9:17 ` Geert Uytterhoeven
0 siblings, 1 reply; 3+ messages in thread
From: Paul Mundt @ 2012-06-18 4:55 UTC (permalink / raw)
To: Linus Torvalds; +Cc: Andi Kleen, linux-kernel
(Apologies for the re-send, forgot to Cc linux-kernel)
When the READABLE_ASM cc-option tests were added they were done so prior
to the arch Makefile include, resulting in cc-option being run on the
host cc instead of the factoring in the cross prefix set up by the
architecture.
This bumps the include back up so that cc-option actually runs on the
compiler that we're building with.
Cc: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
---
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index d845c2a..f5d4f47 100644
--- a/Makefile
+++ b/Makefile
@@ -561,6 +561,8 @@ else
KBUILD_CFLAGS += -O2
endif
+include $(srctree)/arch/$(SRCARCH)/Makefile
+
ifdef CONFIG_READABLE_ASM
# Disable optimizations that make assembler listings hard to read.
# reorder blocks reorders the control in the function
@@ -571,8 +573,6 @@ KBUILD_CFLAGS += $(call cc-option,-fno-reorder-blocks,) \
$(call cc-option,-fno-partial-inlining)
endif
-include $(srctree)/arch/$(SRCARCH)/Makefile
-
ifneq ($(CONFIG_FRAME_WARN),0)
KBUILD_CFLAGS += $(call cc-option,-Wframe-larger-than=${CONFIG_FRAME_WARN})
endif
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] Makefile: fix up CROSS_COMPILE and READABLE_ASM interaction.
2012-06-18 4:55 [PATCH] Makefile: fix up CROSS_COMPILE and READABLE_ASM interaction Paul Mundt
@ 2012-06-19 9:17 ` Geert Uytterhoeven
2012-06-19 12:13 ` Paul Mundt
0 siblings, 1 reply; 3+ messages in thread
From: Geert Uytterhoeven @ 2012-06-19 9:17 UTC (permalink / raw)
To: Paul Mundt
Cc: Linus Torvalds, Andi Kleen, linux-kernel, Linux-Next, Ingo Molnar
On Mon, Jun 18, 2012 at 6:55 AM, Paul Mundt <lethal@linux-sh.org> wrote:
> (Apologies for the re-send, forgot to Cc linux-kernel)
>
> When the READABLE_ASM cc-option tests were added they were done so prior
> to the arch Makefile include, resulting in cc-option being run on the
> host cc instead of the factoring in the cross prefix set up by the
> architecture.
>
> This bumps the include back up so that cc-option actually runs on the
> compiler that we're building with.
I find it a real pity these reported, hard to investigate, and fixed
build issues keep
flowing into mainline, without the corresponding fix...
https://lkml.org/lkml/2012/5/12/36
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@linux-m68k.org
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] Makefile: fix up CROSS_COMPILE and READABLE_ASM interaction.
2012-06-19 9:17 ` Geert Uytterhoeven
@ 2012-06-19 12:13 ` Paul Mundt
0 siblings, 0 replies; 3+ messages in thread
From: Paul Mundt @ 2012-06-19 12:13 UTC (permalink / raw)
To: Geert Uytterhoeven
Cc: Linus Torvalds, Andi Kleen, linux-kernel, Linux-Next, Ingo Molnar
On Tue, Jun 19, 2012 at 11:17:59AM +0200, Geert Uytterhoeven wrote:
> On Mon, Jun 18, 2012 at 6:55 AM, Paul Mundt <lethal@linux-sh.org> wrote:
> > (Apologies for the re-send, forgot to Cc linux-kernel)
> >
> > When the READABLE_ASM cc-option tests were added they were done so prior
> > to the arch Makefile include, resulting in cc-option being run on the
> > host cc instead of the factoring in the cross prefix set up by the
> > architecture.
> >
> > This bumps the include back up so that cc-option actually runs on the
> > compiler that we're building with.
>
> I find it a real pity these reported, hard to investigate, and fixed
> build issues keep
> flowing into mainline, without the corresponding fix...
>
> https://lkml.org/lkml/2012/5/12/36
>
Agreed. These one-off things are always a nuisance, and often fall
through the cracks. I've yet to find a good solution for them, although
having them rolled in to -next helps.
In this case I got bit by -fno-partial-inlining instead, and since you
didn't have READABLE_ASM in the subject I missed your patch entirely. In
retrospect I should have searched for cc-option. At least we've now both
scratched our heads and come up with an identical fix independently,
which counts a lot more than a Tested-by ;-)
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2012-06-19 12:14 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-18 4:55 [PATCH] Makefile: fix up CROSS_COMPILE and READABLE_ASM interaction Paul Mundt
2012-06-19 9:17 ` Geert Uytterhoeven
2012-06-19 12:13 ` Paul Mundt
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox