diff mk/objective.mk @ 3526:56e2a8704164 trunk

Automated merge with ssh://hg.atheme.org//hg/audacious.
author William Pitcock <nenolod@atheme.org>
date Thu, 13 Sep 2007 01:12:43 -0500
parents 7f32f40201a4
children
line wrap: on
line diff
--- a/mk/objective.mk	Thu Sep 13 01:12:05 2007 -0500
+++ b/mk/objective.mk	Thu Sep 13 01:12:43 2007 -0500
@@ -85,7 +85,7 @@
 		done; \
 	fi
 	$(MAKE) clean-posthook
-	rm -f *.o *.lo *.so *.a *.sl .depend-done .depend
+	rm -f *.o *.lo *.so *.a *.sl *.h.gch .depend-done .depend
 	touch .depend
 	@if [ "x$(OBJECTIVE_BINS)" != "x" ]; then \
 		for i in $(OBJECTIVE_BINS); do \
@@ -209,6 +209,16 @@
 	fi;
 	$(CXX) $(CXXFLAGS) -c $< -o $@
 
+pch:
+	@for i in *.h; do \
+		if [ $(SHOW_CFLAGS) -eq 1 ]; then	\
+			printf "%10s     %-20s (%s)\n" "CC [HDR]" $$i "${CFLAGS}";	\
+		else \
+			printf "%10s     %-20s\n" "CC [HDR]" $$i;	\
+		fi; \
+		$(CC) $(CFLAGS) -c $$i -o $$i.gch; \
+	done
+
 $(OBJECTIVE_LIBS): $(OBJECTS)
 	if [ "x$(OBJECTS)" != "x" ]; then \
 		$(MAKE) $(OBJECTS) || exit;		\
@@ -231,7 +241,7 @@
 		$(AR) cr $@ $(OBJECTS); \
 	fi
 
-$(OBJECTIVE_BINS): $(OBJECTS)
+$(OBJECTIVE_BINS): $(SOURCES) $(OBJECTS)
 	if [ "x$(OBJECTS)" != "x" ]; then \
 		$(MAKE) $(OBJECTS) || exit;		\
 		printf "%10s     %-20s\n" LINK $@; \