diff options
author | Arnd Bergmann <arnd@arndb.de> | 2024-11-07 22:26:46 +1100 |
---|---|---|
committer | Michael Ellerman <mpe@ellerman.id.au> | 2024-11-15 11:59:55 +1100 |
commit | a5371018eefdd81f4152926a6d2b9480a75ac2a6 (patch) | |
tree | ba1069ca06279e78e8734e311a8a5341860d3418 /arch/powerpc/kernel/vdso | |
parent | 4aa5cc1e0012f784bc7f637458e597564833b425 (diff) |
powerpc/Makefile: Allow overriding CPP
Unlike all other arches, powerpc doesn't allow the user to override CPP,
because it sets it unconditionally in the arch Makefile. This can lead
to strange build failures.
Instead add the required flags to KBUILD_CPPFLAGS, which are passed
to CPP, CC and AS invocations by the generic Makefile logic.
Reported-by: Arnd Bergmann <arnd@arndb.de>
Tested-by: Nathan Chancellor <nathan@kernel.org>
Reviewed-by: Nathan Chancellor <nathan@kernel.org>
Closes: https://lore.kernel.org/all/20240607061629.530301-1-arnd@kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
[mpe: Rebase, write change log, add Arnd's SoB as communicated privately]
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://patch.msgid.link/20241107112646.32401-1-mpe@ellerman.id.au
Diffstat (limited to 'arch/powerpc/kernel/vdso')
-rw-r--r-- | arch/powerpc/kernel/vdso/Makefile | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/powerpc/kernel/vdso/Makefile b/arch/powerpc/kernel/vdso/Makefile index c568cad6a22e..0e3ed6fb199f 100644 --- a/arch/powerpc/kernel/vdso/Makefile +++ b/arch/powerpc/kernel/vdso/Makefile @@ -50,7 +50,7 @@ ldflags-$(CONFIG_LD_IS_LLD) += $(call cc-option,--ld-path=$(LD),-fuse-ld=lld) ldflags-$(CONFIG_LD_ORPHAN_WARN) += -Wl,--orphan-handling=$(CONFIG_LD_ORPHAN_WARN_LEVEL) # Filter flags that clang will warn are unused for linking -ldflags-y += $(filter-out $(CC_AUTO_VAR_INIT_ZERO_ENABLER) $(CC_FLAGS_FTRACE) -Wa$(comma)%, $(KBUILD_CFLAGS)) +ldflags-y += $(filter-out $(CC_AUTO_VAR_INIT_ZERO_ENABLER) $(CC_FLAGS_FTRACE) -Wa$(comma)%, $(KBUILD_CPPFLAGS) $(KBUILD_CFLAGS)) CC32FLAGS := -m32 CC32FLAGSREMOVE := -mcmodel=medium -mabi=elfv1 -mabi=elfv2 -mcall-aixdesc |