Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

use clang for compilation if available, otherwise fallback to gcc

  • Loading branch information...
commit c3eb86e3fc8455e7cc88efdcba381b5a913d51b4 1 parent 033b9c4
@ekarak ekarak authored
Showing with 9 additions and 2 deletions.
  1. +9 −2 Makefile
View
11 Makefile
@@ -7,10 +7,17 @@
.SUFFIXES: .cpp .o .a .s .thrift
-#CC := gcc
-#CXX := g++
+# Sorry gcc, clang is way better.
+# Use it if found in path...
+CLANG := $(shell which clang)
+ifeq ($(CLANG),)
+CC := gcc
+CXX := g++
+else
CC := clang
CXX := clang++
+endif
+
LD := ld
AR := ar rc
RANLIB := ranlib
Please sign in to comment.
Something went wrong with that request. Please try again.