[cairo] Bug compiling cairo in AIX

Chris Wilson chris at chris-wilson.co.uk
Wed Oct 31 05:33:51 PDT 2007

Rajesh Narayanan (rajnaran_amb at hotmail.com) said: 
> This is the error I got when running make against Cairo 1.4.10 in AIX 5.2
>  cairo-png.c: In function `png_simple_error_callback'
>  cairo-png.c:95: error: structure has no member named `__jmpbuf'
> Could anybody please help me.

Google's suggestion is to to include png.h last (after the system header
that redefines jmpbuf), but alas that is already the case within
cairo-png.c. So we have to try the other approach and to undef jmpbuf
within cairo-png.c, viz:

diff --git a/src/cairo-png.c b/src/cairo-png.c
index ee7e5fd..c79b543 100644
--- a/src/cairo-png.c
+++ b/src/cairo-png.c
@@ -40,6 +40,8 @@
 #include <errno.h>
 #include <png.h>
+#undef jmpbuf

Can you try that change and report whether cairo functions correctly
afterwards? Thanks.
Chris Wilson

More information about the cairo mailing list