[cairo-commit] src/Makefile.am.analysis

Behdad Esfahbod behdad at kemper.freedesktop.org
Sun Feb 20 15:16:33 PST 2011


 src/Makefile.am.analysis |    5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

New commits:
commit 90e1ef2d80b252cdc528d8d8d57cace109034e0b
Author: Behdad Esfahbod <behdad at behdad.org>
Date:   Sun Feb 20 18:16:10 2011 -0500

    Bug 34011 - headers-standalone target is incorrect for some non-gcc compilers

diff --git a/src/Makefile.am.analysis b/src/Makefile.am.analysis
index 2822320..f10a03f 100644
--- a/src/Makefile.am.analysis
+++ b/src/Makefile.am.analysis
@@ -24,7 +24,10 @@ headers-standalone: $(enabled_cairo_headers) $(enabled_cairo_private)
 	@echo Checking that enabled public/private headers can be compiled standalone
 	@status=true; for f in $(enabled_cairo_headers) $(enabled_cairo_private); do \
 		echo "  CHECK $$f"; \
-		$(COMPILE) -o /dev/null $(srcdir)/$$f || status=false; \
+		echo "#include \"$(srcdir)/$$f\"" > headers-standalone-tmp.c; \
+		echo "int main(int argc, char * argv[]) {}" >> headers-standalone-tmp.c; \
+		$(COMPILE) -o /dev/null headers-standalone-tmp.c || status=false; \
+		$(RM) headers-standalone-tmp.c; \
 	done; $$status
 	@touch $@
 CLEANFILES += headers-standalone


More information about the cairo-commit mailing list