[cairo] Compiling for Cairo development BUGS?

Koen Kooi k.kooi at student.utwente.nl
Sun Jun 13 12:08:29 PDT 2010


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 13-06-10 20:25, Bill Spitzak wrote:
> Can somebody please tell me if the "libcairo.la" in cairo-unsupported.pc
> is an error that should be fixed?
> 
> I have the absolute newest gcc and it does not think a ".la" file is
> something that should be on on the link line.

Aren't you supposed to use libtool to call your linker e.g.
$targetprefix-libtool --mode link something something? Libtool knows
about .l(ibtool)a(rchives) files, gcc doesn't.

regards,

Koen

> 
> Also an explanation of the "PKG_CONFIG_TOP_BUILD_DIR" would help. Am I
> supposed to set this or is the text in the .pc file in error that causes
> that to matter?
> 
> On Jun 10, 2010, at 1:55 PM, Bill Spitzak wrote:
> 
>> On 05/24/2010 07:14 AM, Chris Wilson wrote:
>>> On Mon, 24 May 2010 10:10:27 +0200, Arjen
>>> Nienhuis<a.g.nienhuis at gmail.com>  wrote:
>>>> Hi,
>>>>
>>>> You use this for pixman, cairo and the app that needs cairo:
>>>>
>>>> PREFIX=$HOME/whatever
>>>> PKG_CONFIG_PATH=$PREFIX/lib/pkgconfig ./autogen.sh --prefix=$PREFIX
>>>
>>> Cairo and pixman should both support uninstalled .pc, so compile
>>> pixman as
>>> normal and then try for cairo:
>>>   PKG_CONFIG_PATH=$pixmandir ./autogen.sh
>>> and
>>>   PKG_CONFIG_PATH=$pixmandir:$cairodir ./autogen.sh
>>> for your application.
>>> -ickle
>>
>> This allowed both pixman and cairo to compile, but I cannot build
>> applications using it and pkg-config. In my setup pixman, cairo, and
>> my application are all directories at the same level, and when
>> building the application I am in the applications directory.
>>
>> First it appears PKG_CONFIG_TOP_BUILD_DIR is needed (though that seems
>> to be a stupid pkg-config bug, they should default to '.' rather than
>> producing a $(xxx) text that will not be substututed if you put
>> pkg-config inside `` in a shell.
>>
>> But then:
>>
>> PKG_CONFIG_TOP_BUILD_DIR=. PKG_CONFIG_PATH=../cairo:../pixman
>> pkg-config --cflags --libs pangocairo
>>
>> -pthread -I./../cairo/./src -I./../pixman/pixman
>> -I/usr/include/pango-1.0 -I/usr/include/glib-2.0
>> -I/usr/lib/glib-2.0/include -I/usr/include/freetype2
>> -I/usr/include/libpng12  ./../cairo/src/libcairo.la -pthread
>> -lpangocairo-1.0 -lpango-1.0 -lgobject-2.0 -lgmodule-2.0 -lgthread-2.0
>> -lrt -lglib-2.0
>>
>> This result specifies a file called libcairo.la. The gcc compiler does
>> not like that file (it is a "libtool library file").
>>
>> Patching the file cairo-uninstalled.pc to specify the
>> .libs/libcairo.so.2 instead of libcairo.la fixes this but I am not
>> sure if that is the solution. I still need to set LD_LIBRARY_PATH to
>> use it, I would prefer a solution that forces the full path name into
>> the compiled program, and/or makes a .a file be used instead of a .so.
> 
> -- 
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo
> 

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.5 (Darwin)

iD8DBQFMFSytMkyGM64RGpERAsp9AJ9YINIl5g+jD86JgGWfkRXb9T7JggCeLfLe
HF9P66Zn4Atv1tgc2RJChv4=
=nsTA
-----END PGP SIGNATURE-----



More information about the cairo mailing list