summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--config/Make.rules.Darwin10
1 files changed, 7 insertions, 3 deletions
diff --git a/config/Make.rules.Darwin b/config/Make.rules.Darwin
index 424587789ae..9496f5a979d 100644
--- a/config/Make.rules.Darwin
+++ b/config/Make.rules.Darwin
@@ -6,13 +6,17 @@
supported-platforms = macosx iphoneos iphonesimulator
-homebrew := $(shell brew --prefix)
+homebrew := $(shell brew --prefix 2> /dev/null)
+
+# By default, use mcpp and lmdb from homebrew
+MCPP_HOME ?= $(if $(homebrew),$(homebrew)/opt/mcpp)
+LMDB_HOME ?= $(if $(homebrew),$(homebrew)/opt/lmdb)
macosx_ar = libtool
macosx_cc = xcrun -sdk macosx clang
macosx_cxx = xcrun -sdk macosx clang++
-macosx_cppflags = -mmacosx-version-min=10.9 -arch x86_64 -I$(homebrew)/include
-macosx_ldflags = $(macosx_cppflags) -L$(homebrew)/lib
+macosx_cppflags = -mmacosx-version-min=10.9 -arch x86_64
+macosx_ldflags = $(macosx_cppflags)
macosx_targetdir = $(if $(filter %/build,$5),/macosx)
iphoneos_ar = libtool