Add option on OSX to use macports (#1675)

This commit is contained in:
saihttam 2016-10-18 18:56:00 +02:00 committed by Tianqi Chen
parent 445029bb82
commit 4b9d488387

View File

@ -43,8 +43,8 @@ endif
# it is useful for pip install compiling-on-the-fly # it is useful for pip install compiling-on-the-fly
OS := $(shell uname) OS := $(shell uname)
ifeq ($(OS), Darwin) ifeq ($(OS), Darwin)
export CC = $(if $(shell which gcc-6),gcc-6,clang) export CC = $(if $(shell which gcc-6),gcc-6,$(if $(shell which gcc-mp-6), gcc-mp-6, clang))
export CXX = $(if $(shell which g++-6),g++-6,clang++) export CXX = $(if $(shell which g++-6),g++-6,$(if $(shell which g++-mp-6),g++-mp-6, clang++))
endif endif
export LDFLAGS= -pthread -lm $(ADD_LDFLAGS) $(DMLC_LDFLAGS) $(PLUGIN_LDFLAGS) export LDFLAGS= -pthread -lm $(ADD_LDFLAGS) $(DMLC_LDFLAGS) $(PLUGIN_LDFLAGS)