From 8f6e535edcb2e81b92e5569d31088a54812409f3 Mon Sep 17 00:00:00 2001 From: Julia Longtin Date: Tue, 12 Mar 2024 21:54:38 +0000 Subject: [PATCH] try to detect the PHI cross compiler in make. --- Makefile | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index 9a6bc2f14..1e778c21f 100644 --- a/Makefile +++ b/Makefile @@ -121,7 +121,7 @@ CC := riscv64-unknown-linux-gnu-gcc CXX := riscv64-unknown-linux-gnu-g++ endif -K1OM := $( shell echo | $CC -dM -E - | grep __k1om__ ) +K1OM := $(shell echo | $(CC) -dM -E - | grep __k1om__) # # Compile flags @@ -310,7 +310,8 @@ ifndef RISCV ifeq ($(UNAME_M),$(filter $(UNAME_M),x86_64 i686 amd64)) -ifeq "$(K1OM)" "" +# detect the PHI cross compiler. +ifeq "${K1OM}" "" # Use all CPU extensions that are available: MK_CFLAGS += -march=native -mtune=native