ARM clang doesn't support -march=native.

This commit is contained in:
Bartosz Taudul 2021-01-26 19:46:39 +01:00
parent 62d6f4127d
commit c8ea47782c
5 changed files with 12 additions and 4 deletions

View File

@ -1,4 +1,4 @@
CFLAGS := -O3 -march=native
CFLAGS := -O3
DEFINES := -DNDEBUG
BUILD := release

View File

@ -1,3 +1,11 @@
ARCH := $(shell uname -m)
ifeq (0,$(shell $(CC) --version | grep clang && echo 1 || echo 0))
CFLAGS += -s
endif
ifeq ($(ARCH),aarch64)
CFLAGS += -mcpu=native
else
CFLAGS += -march=native
endif

View File

@ -1,4 +1,4 @@
CFLAGS := -O3 -march=native
CFLAGS := -O3
DEFINES := -DNDEBUG
BUILD := release

View File

@ -1,4 +1,4 @@
CFLAGS := -O3 -march=native
CFLAGS := -O3
DEFINES := -DNDEBUG
BUILD := release

View File

@ -1,4 +1,4 @@
CFLAGS := -O3 -march=native
CFLAGS := -O3
DEFINES := -DNDEBUG
BUILD := release