From c35f822f1cba9d8cca47eab626749bc23026d6d0 Mon Sep 17 00:00:00 2001 From: Timothy Warren Date: Tue, 21 Apr 2015 21:41:56 -0400 Subject: [PATCH] Use clang to compile if installed --- Makefile | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index abb47b9..4afb633 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,9 @@ -CXX = $(shell wx-config --cxx) -I/include +#Try using clang, if it's installed +ifneq ($(shell which clang),clang not found) + CXX = $(patsubst g++,clang++, $(shell wx-config --cxx)) -std=c++11 -I/include +else + CXX = $(shell wx-config --cxx) -I/include +endif SOURCES = $(wildcard include/**/*.cpp src/network/*.cpp src/settings/*.cpp include/*.cpp) OBJECTS = $(patsubst %.cpp,%.o, $(SOURCES))