Use clang as the default C compiler
Clang compiles faster than GCC and is supposed to give more meaningful error messages, so let's use it at least for development. OwlPS Positioner does not compile with clang++, so we are stuck with g++ (or colorgcc).
This commit is contained in:
parent
437c5fec8c
commit
24a07f9e01
11
common.mk
11
common.mk
|
@ -53,9 +53,14 @@ SYMLINK := ln -sf
|
|||
|
||||
# C compiler
|
||||
ifeq "$(origin CC)" "default"
|
||||
COLORGCC := $(shell which colorgcc >/dev/null 2>&1 ; echo $$?)
|
||||
ifeq "$(COLORGCC)" "0"
|
||||
CC := colorgcc
|
||||
CLANG := $(shell command -v clang >/dev/null ; echo $$?)
|
||||
ifeq "$(CLANG)" "0"
|
||||
CC := clang
|
||||
else
|
||||
COLORGCC := $(shell command -v colorgcc >/dev/null ; echo $$?)
|
||||
ifeq "$(COLORGCC)" "0"
|
||||
CC := colorgcc
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
|
|
Loading…
Reference in New Issue