[cairo] patch for the out-of-the-source-tree builds of cairo

Bob Jamison rjamison at titan.com
Wed Jun 1 16:22:31 PDT 2005


Tomasz,

This is exactly the scenario I am working with, too.  Using my own
make tree from 'above' the Cairo distro.   Nice idea.

Bob



Tomasz Cholewo wrote:

>Building cairo in a directory separate from the source fails because the
>generated header cairo-features.h is not on any include path when
>compiling files in the cairo/test subdirectory.  The attached proposed
>patch adds $(top_builddir)/src to the header search path.  I also attach
>a make log showing the error.
>
>Regards,
>  Tomasz Cholewo
>  
>
>------------------------------------------------------------------------
>
>diff -rN -u old-cairo/test/Makefile.am new-cairo/test/Makefile.am
>--- old-cairo/test/Makefile.am	2005-06-01 18:49:35.717697979 -0400
>+++ new-cairo/test/Makefile.am	2005-06-01 15:47:18.000000000 -0400
>@@ -104,7 +104,7 @@
> # not be the most portable approach, but it is pragmatic and I'm
> # willing to do something cleaner as soon as it causes someone a
> # problem.
>-INCLUDES = -D_GNU_SOURCE -I$(srcdir) $(CAIRO_CFLAGS) -I$(top_srcdir)/src
>+INCLUDES = -D_GNU_SOURCE -I$(srcdir) $(CAIRO_CFLAGS) -I$(top_srcdir)/src -I$(top_builddir)/src
> 
> noinst_LTLIBRARIES = libcairotest.la
> 
>
>  
>
>------------------------------------------------------------------------
>
>source in /cairo/cairo
>building in /cairo/build-debug/cairo
>
>PKG_CONFIG_PATH=/cairo/build-debug/lib/pkgconfig/: ../../cairo/configure CFLAGS=-g --prefix=/cairo/build-debug
>
>make
>
>[...]
>Making all in test
>make[2]: Entering directory `/cairo/build-debug/cairo/test'
>[...]
> gcc -DHAVE_CONFIG_H -I. -I../../../cairo/test -I.. -D_GNU_SOURCE -I../../../cairo/test -I/usr/include/libpng12 -I/cairo/build-debug/include -I/usr/include/freetype2 -Wall -Wpointer-arith -Wstrict-prototypes -Wmissing-prototypes -Wmissing-declarations -Wnested-externs -fno-strict-aliasing -I../../../cairo/src -g -MT buffer-diff.lo -MD -MP -MF .deps/buffer-diff.Tpo -c ../../../cairo/test/buffer-diff.c  -fPIC -DPIC -o .libs/buffer-diff.o
>In file included from ../../../cairo/test/cairo-test.h:30,
>                 from ../../../cairo/test/buffer-diff.c:31:
>../../../cairo/src/cairo.h:49:28: cairo-features.h: No such file or directory
>  
>





More information about the cairo mailing list