From f5fab305405f7c4ae4a953036cf38720707d25f3 Mon Sep 17 00:00:00 2001 From: KatolaZ Date: Thu, 30 Apr 2020 16:11:00 +0100 Subject: [PATCH] fix compiler detection --- Reducibility_Multiplex/Makefile | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/Reducibility_Multiplex/Makefile b/Reducibility_Multiplex/Makefile index 01e71fa..d78d27c 100644 --- a/Reducibility_Multiplex/Makefile +++ b/Reducibility_Multiplex/Makefile @@ -4,20 +4,20 @@ LDFLAGS=-lm -lgmp -lz HAVE_CC=$(shell $(CC) --version ; echo \$?) -IS_CC_GCC=$(shell $(CC) --version | grep -Eic 'gcc' || echo "0") -IS_CC_CLANG=$(shell $(CC) --version | grep -Eic '(llvm|clang)' || echo "0") -IS_CC_ICC=$(shell $(CC) --version | grep -Eic 'Intel' || echo "0") +IS_CC_GCC=$(shell $(CC) --version | grep -Eic 'gcc' || echo "NUL") +IS_CC_CLANG=$(shell $(CC) --version | grep -Eic '(llvm|clang)' || echo "NUL") +IS_CC_ICC=$(shell $(CC) --version | grep -Eic 'Intel' || echo "NUL") -ifeq ($(IS_CC_GCC), 1) +ifneq ($(IS_CC_GCC),"NUL") # compiler is GCC CFLAGS+=-fopenmp else - ifeq ($(IS_CC_CGLANG), 1) + ifneq ($(IS_CC_CGLANG), "NUL") # compiler is CLANG LDFLAGS+=-lomp else - ifeq ($(IS_CC_ICC), 1) + ifneq ($(IS_CC_ICC), "NUL") # compiler is Intel icc CFLAGS+=-qopenmp endif