diff mbox series

[1/2] Makefile: Export clang toolchain variables

Message ID 20181104231133.30848-2-joel@jms.id.au
State New
Headers show
Series poewrpc/Boot: Fix cross compiling with clang | expand

Commit Message

Joel Stanley Nov. 4, 2018, 11:11 p.m. UTC
The powerpc makefile will use these in it's boot wrapper.

Signed-off-by: Joel Stanley <joel@jms.id.au>

---
 Makefile | 3 +++
 1 file changed, 3 insertions(+)

-- 
2.19.1

Comments

Daniel Axtens Nov. 5, 2018, 12:10 a.m. UTC | #1
Hi Joel,

Thanks!

Tested-by: Daniel Axtens <dja@axtens.net> # powerpc 64-bit BE


Regards,
Daniel

> The powerpc makefile will use these in it's boot wrapper.

>

> Signed-off-by: Joel Stanley <joel@jms.id.au>

> ---

>  Makefile | 3 +++

>  1 file changed, 3 insertions(+)

>

> diff --git a/Makefile b/Makefile

> index 9aa352b38815..a2db3c885b38 100644

> --- a/Makefile

> +++ b/Makefile

> @@ -495,6 +495,9 @@ endif

>  ifneq ($(GCC_TOOLCHAIN),)

>  CLANG_GCC_TC	:= --gcc-toolchain=$(GCC_TOOLCHAIN)

>  endif

> +export CLANG_TARGET

> +export CLANG_GCC_TC

> +export CLANG_PREFIX

>  KBUILD_CFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)

>  KBUILD_AFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)

>  KBUILD_CFLAGS += $(call cc-option, -no-integrated-as)

> -- 

> 2.19.1
Masahiro Yamada Nov. 5, 2018, 2:52 a.m. UTC | #2
Hi Joel,


On Mon, Nov 5, 2018 at 9:53 AM Joel Stanley <joel@jms.id.au> wrote:
>

> The powerpc makefile will use these in it's boot wrapper.

>

> Signed-off-by: Joel Stanley <joel@jms.id.au>

> ---

>  Makefile | 3 +++

>  1 file changed, 3 insertions(+)

>

> diff --git a/Makefile b/Makefile

> index 9aa352b38815..a2db3c885b38 100644

> --- a/Makefile

> +++ b/Makefile

> @@ -495,6 +495,9 @@ endif

>  ifneq ($(GCC_TOOLCHAIN),)

>  CLANG_GCC_TC   := --gcc-toolchain=$(GCC_TOOLCHAIN)

>  endif

> +export CLANG_TARGET

> +export CLANG_GCC_TC

> +export CLANG_PREFIX

>  KBUILD_CFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)

>  KBUILD_AFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)

>  KBUILD_CFLAGS += $(call cc-option, -no-integrated-as)

> --

> 2.19.1

>



Before exporting these compiler flags,
I'd like to do a cleanup work.


Could you take a look at my patch, please?

https://patchwork.kernel.org/patch/10667369/


By using it as a prerequisite,
your patch set will be more simplified.


-- 
Best Regards
Masahiro Yamada
diff mbox series

Patch

diff --git a/Makefile b/Makefile
index 9aa352b38815..a2db3c885b38 100644
--- a/Makefile
+++ b/Makefile
@@ -495,6 +495,9 @@  endif
 ifneq ($(GCC_TOOLCHAIN),)
 CLANG_GCC_TC	:= --gcc-toolchain=$(GCC_TOOLCHAIN)
 endif
+export CLANG_TARGET
+export CLANG_GCC_TC
+export CLANG_PREFIX
 KBUILD_CFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)
 KBUILD_AFLAGS += $(CLANG_TARGET) $(CLANG_GCC_TC) $(CLANG_PREFIX)
 KBUILD_CFLAGS += $(call cc-option, -no-integrated-as)