diff src/Makefile.am @ 308:6cb3c072be3f

ui_icons.h and icons_inline.h depend on gdk-pixbuf-csource, so add a test for it in configure. Wrap generated headers files with #ifdef/#endif and add a comment related to their auto-generated nature. Make the generation itself quiet, but display a message on error. Make these targets depend on respective Makefile.in.
author zas_
date Fri, 11 Apr 2008 13:07:48 +0000
parents 667e49f52168
children 5afe77bb563a
line wrap: on
line diff
--- a/src/Makefile.am	Fri Apr 11 12:31:32 2008 +0000
+++ b/src/Makefile.am	Fri Apr 11 13:07:48 2008 +0000
@@ -36,8 +36,12 @@
 	icon_spinner		$(srcdir)/ui_spinner.png	\
 	icon_tabcomp		$(srcdir)/ui_tabcomp.png
 
-ui_icons.h: $(extra_ICONS)
-	gdk-pixbuf-csource --raw --extern --build-list $(ICON_PAIRS) > ui_icons.h
+ui_icons.h: $(extra_ICONS) Makefile.in
+	@(echo '/* Auto generated file, do not edit */'; echo; \
+	 echo '#ifndef UI_ICONS_H'; \
+	 echo '#define UI_ICONS_H'; echo; \
+	 $(GDK_PIXBUF_CSOURCE) --raw --extern --build-list $(ICON_PAIRS); \
+	 echo '#endif /* UI_ICONS_H */') > $@ || echo "!!! Failed to generate $@ !!!"
 
 ui_spinner.o: ui_icons.h