From 566c3ed3c36fae94fa6bcc26ecc28d4a0d01207a Mon Sep 17 00:00:00 2001 From: Mark Charlebois Date: Wed, 11 Mar 2015 14:22:31 -0700 Subject: [PATCH] Linux: Autodetect clang-3.5 toolchain Use clang-3.5 if found, otherwise gcc Signed-off-by: Mark Charlebois --- makefiles/toolchain_native.mk | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/makefiles/toolchain_native.mk b/makefiles/toolchain_native.mk index 37e5dbed51..5691e87a9f 100644 --- a/makefiles/toolchain_native.mk +++ b/makefiles/toolchain_native.mk @@ -39,7 +39,13 @@ # # Set to 1 for GCC-4.8.2 and to 0 for Clang-3.5 (Ubuntu 14.04) + +HAVE_CLANG35=$(shell clang-3.6 --version) +ifeq ($(HAVE_CLANG35),) +USE_GCC=1 +else USE_GCC=0 +endif ifeq ($(USE_GCC),1) # GCC Options: