aboutsummaryrefslogtreecommitdiff
path: root/Makefile.main
diff options
context:
space:
mode:
authorJoel Stanley <joel@jms.id.au>2018-05-04 11:40:26 +0930
committerStewart Smith <stewart@linux.ibm.com>2018-05-04 03:25:04 -0500
commit1f1b3b4ed20432d487a9da05b57b3559330e8358 (patch)
treebca6501718239879b6abb85fd5cc7d22c32c12f9 /Makefile.main
parent7a8214eeb1c5beacb2f780e419d60afa7b65b844 (diff)
downloadskiboot-1f1b3b4ed20432d487a9da05b57b3559330e8358.zip
skiboot-1f1b3b4ed20432d487a9da05b57b3559330e8358.tar.gz
skiboot-1f1b3b4ed20432d487a9da05b57b3559330e8358.tar.bz2
Makefile: Put some ppc options behind try-cflag tests
Clang errors out when attempting to build with these flags present. Signed-off-by: Joel Stanley <joel@jms.id.au> Signed-off-by: Stewart Smith <stewart@linux.ibm.com>
Diffstat (limited to 'Makefile.main')
-rw-r--r--Makefile.main6
1 files changed, 3 insertions, 3 deletions
diff --git a/Makefile.main b/Makefile.main
index 584d46d..72b6821 100644
--- a/Makefile.main
+++ b/Makefile.main
@@ -69,7 +69,7 @@ endif
CFLAGS := -fno-strict-aliasing -pie -fpie -fno-pic -mbig-endian -m64
CFLAGS += -mcpu=power7
CFLAGS += -Wl,--oformat,elf64-powerpc
-CFLAGS += -ffixed-r13
+CFLAGS += $(call try-cflag,$(CC),-ffixed-r13)
CFLAGS += $(call try-cflag,$(CC),-std=gnu11)
ifeq ($(ELF_ABI_v2),1)
CFLAGS += $(call try-cflag,$(CC),-mabi=elfv2)
@@ -146,9 +146,9 @@ endif
# Do not use the floating point unit
CFLAGS += -msoft-float
# Do not use string instructions
-CFLAGS += -mno-string
+CFLAGS += $(call try-cflag,$(CC),-mno-string)
# do not use load/store multiple word instrcutions
-CFLAGS += -mno-multiple
+CFLAGS += $(call try-cflag,$(CC),-mno-multiple)
# do not use any automatic vector foo
# While it would be safe during boot, we don't save/restore across OPAL calls
CFLAGS += $(call try-cflag,$(CC),-mno-vsx) \