fixed other error in compiler check

enzo-makefile
KatolaZ 5 years ago
parent f5fab30540
commit 74f2ff7d47
  1. 24
      Reducibility_Multiplex/Makefile

@ -2,26 +2,24 @@ CC=gcc
CFLAGS=-O2
LDFLAGS=-lm -lgmp -lz
HAVE_CC=$(shell $(CC) --version ; echo \$?)
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")
IS_CC_GCC=$(shell $(CC) --version 2>/dev/null | grep -Eic 'gcc')
IS_CC_CLANG=$(shell $(CC) --version | grep -Eic '(llvm|clang)')
IS_CC_ICC=$(shell $(CC) --version | grep -Eic 'Intel')
ifneq ($(IS_CC_GCC),"NUL")
ifneq ($(IS_CC_GCC), 0)
# compiler is GCC
CFLAGS+=-fopenmp
CFLAGS+=-fopenmp
else
ifneq ($(IS_CC_CGLANG), "NUL")
ifneq ($(IS_CC_CLANG), 0)
# compiler is CLANG
LDFLAGS+=-lomp
else
ifneq ($(IS_CC_ICC), "NUL")
LDFLAGS+=-lomp
else
ifneq($(IS_CC_ICC), 0)
# compiler is Intel icc
CFLAGS+=-qopenmp
endif
endif
CFLAGS+=-qopenmp
endif
endif

Loading…
Cancel
Save