aboutsummaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorAndrew Jones <ajones@ventanamicro.com>2023-08-10 14:15:28 +0200
committerAnup Patel <anup@brainfault.org>2023-08-22 13:26:03 +0530
commit7aabeee93edb2e7ab03954e235683bfd9d8f29eb (patch)
tree55e5a345719ddc6bae4d4d57c86342b2abae2c4a /Makefile
parentc104c60912a4ed26093f00a9675ad0286e8dcd29 (diff)
downloadopensbi-7aabeee93edb2e7ab03954e235683bfd9d8f29eb.zip
opensbi-7aabeee93edb2e7ab03954e235683bfd9d8f29eb.tar.gz
opensbi-7aabeee93edb2e7ab03954e235683bfd9d8f29eb.tar.bz2
Makefile: Fix grep warning
grep (at least my version, grep-3.8-3.fc38.x86_64) warns with "grep: warning: stray \ before -". Fix the warning by making the command line input to grep less ambiguous. Signed-off-by: Andrew Jones <ajones@ventanamicro.com> Reviewed-by: Anup Patel <anup@brainfault.org>
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile2
1 files changed, 1 insertions, 1 deletions
diff --git a/Makefile b/Makefile
index 730dbd9..ca70949 100644
--- a/Makefile
+++ b/Makefile
@@ -168,7 +168,7 @@ endif
OPENSBI_LD_PIE := $(shell $(CC) $(CLANG_TARGET) $(RELAX_FLAG) $(USE_LD_FLAG) -fPIE -nostdlib -Wl,-pie -x c /dev/null -o /dev/null >/dev/null 2>&1 && echo y || echo n)
# Check whether the compiler supports -m(no-)save-restore
-CC_SUPPORT_SAVE_RESTORE := $(shell $(CC) $(CLANG_TARGET) $(RELAX_FLAG) -nostdlib -mno-save-restore -x c /dev/null -o /dev/null 2>&1 | grep "\-save\-restore" >/dev/null && echo n || echo y)
+CC_SUPPORT_SAVE_RESTORE := $(shell $(CC) $(CLANG_TARGET) $(RELAX_FLAG) -nostdlib -mno-save-restore -x c /dev/null -o /dev/null 2>&1 | grep -e "-save-restore" >/dev/null && echo n || echo y)
# Check whether the assembler and the compiler support the Zicsr and Zifencei extensions
CC_SUPPORT_ZICSR_ZIFENCEI := $(shell $(CC) $(CLANG_TARGET) $(RELAX_FLAG) -nostdlib -march=rv$(OPENSBI_CC_XLEN)imafd_zicsr_zifencei -x c /dev/null -o /dev/null 2>&1 | grep "zicsr\|zifencei" > /dev/null && echo n || echo y)