proper windows clang version detection (nw)

make OVERRIDE_CXX=clang++ OVERRIDE_CC=clang
This commit is contained in:
Miodrag Milanovic 2015-12-07 13:05:25 +01:00
parent e706b93447
commit f540242c73

View File

@ -731,9 +731,8 @@ SRC = src
ifeq ($(OS),windows)
GCC_VERSION := $(shell $(subst @,,$(CC)) -dumpversion 2> NUL)
CLANG_VERSION :=
CLANG_VERSION := $(shell $(subst @,,$(CC)) --version 2> NUL| head -n 1 | sed "s/^.*[^0-9]\([0-9]*\.[0-9]*\.[0-9]*\).*$$/\1/")
PYTHON_AVAILABLE := $(shell $(PYTHON) --version > NUL 2>&1 && echo python)
CHECK_CLANG :=
ifdef MSBUILD
MSBUILD_PARAMS := /v:minimal /m:$(NUMBER_OF_PROCESSORS)
ifeq ($(CONFIG),debug)
@ -758,7 +757,6 @@ ifneq ($(OS),solaris)
CLANG_VERSION := $(shell $(subst @,,$(CC)) --version 2> /dev/null | head -n 1 | grep -e 'version [0-9]\.[0-9]\(\.[0-9]\)\?' -o | grep -e '[0-9]\.[0-9]\(\.[0-9]\)\?' -o | tail -n 1)
endif
PYTHON_AVAILABLE := $(shell $(PYTHON) --version > /dev/null 2>&1 && echo python)
CHECK_CLANG := $(shell $(subst @,,$(CC)) --version 2> /dev/null | grep 'clang' | head -n 1)
endif
ifeq ($(CLANG_VERSION),)
$(info GCC $(GCC_VERSION) detected)