From 3f9ce874eb3efbce4272abbbd7fb6d17cb258cbc Mon Sep 17 00:00:00 2001 From: Scott Beamer Date: Sun, 14 Sep 2014 09:10:28 -0700 Subject: [PATCH] now can build with clang on os x, clang needs different flags than gcc to generate and use precompiled headers --- Makefile.in | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Makefile.in b/Makefile.in index 7bbf1d8..c3f7dc0 100644 --- a/Makefile.in +++ b/Makefile.in @@ -191,7 +191,8 @@ $(2)_deps := $$(patsubst %.o, %.d, $$($(2)_objs)) $(2)_c_deps := $$(patsubst %.o, %.d, $$($(2)_c_objs)) $$($(2)_pch) : %.h.gch : %.h $(COMPILE) $$< -$$($(2)_objs) : %.o : %.cc $$($(2)_gen_hdrs) $$($(2)_pch) +# If using clang, don't depend (and thus don't build) precompiled headers +$$($(2)_objs) : %.o : %.cc $$($(2)_gen_hdrs) $(if $(filter-out clang,$(CC)),$$($(2)_pch)) $(COMPILE) -c $$< $$($(2)_c_objs) : %.o : %.c $$($(2)_gen_hdrs) $(COMPILE_C) -c $$< -- 2.30.2