mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* [PATCH] ppc: Test for compiler options
@ 2020-04-27 19:13 Sascha Hauer
  2020-04-28  9:41 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Sascha Hauer @ 2020-04-27 19:13 UTC (permalink / raw)
  To: Barebox List

The -mno-spe and -mspe=no options are not available on all compilers.
Call cc-option to set them only when they exist.

Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
---
 arch/ppc/Makefile | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/arch/ppc/Makefile b/arch/ppc/Makefile
index ebf60edede..67b4b930e7 100644
--- a/arch/ppc/Makefile
+++ b/arch/ppc/Makefile
@@ -4,6 +4,9 @@ CPPFLAGS += -ffixed-r14 -m32 	\
 	-meabi -D __PPC__ -D CONFIG_PPC \
 	-fno-strict-aliasing -mno-spe -mspe=no
 
+CPPFLAGS += $(call cc-option,-mno-spe)
+CPPFLAGS += $(call cc-option,-mspe=no)
+
 ifdef CONFIG_RELOCATABLE
 CPPFLAGS += -fPIC -mrelocatable
 endif
-- 
2.26.2


_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-28  9:42 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-04-27 19:13 [PATCH] ppc: Test for compiler options Sascha Hauer
2020-04-28  9:41 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox