[cairo] configure script does not find pthreads when librt.a is present

Andrea Canciani ranma42 at gmail.com
Mon Oct 1 02:33:45 PDT 2012


On Thu, Sep 27, 2012 at 9:09 PM, Eric Gallager <egall at gwmail.gwu.edu> wrote:
> I was one of the users originally experiencing the problem. Here are my
> config.log's:
>
> http://pastebin.com/WMedpvgG
>
> http://pastebin.com/hM2eGNJM
>
> (there are 2 because I was using the universal variants)
>
> Moving aside my /usr/local solved my problem, so cairo now builds properly
> for me.
>
>
> On Fri, Sep 21, 2012 at 4:16 AM, Ryan Schmidt
> <cairo-2012b at ryandesign.com> wrote:
>> I'm forwarding to you a bug report from a MacPorts user. There is
>> apparently a problem with the cairo configure script where it will
>> incorrectly find a /usr/local/lib/librt.a and try to find symbols in it,
>> which it should be finding in libsystem.dylib instead. Here is our bug
>> report about this:
>
> The problem seems to be some kind of invalid environment for the
> compiler (currently the pthread check is very paranoid, so it will
> fail even upon warnings).
> The issue might be related to
> https://bugs.freedesktop.org/show_bug.cgi?id=30910
> The config.log file should contain some more details about the failure.

The logs confirm that the failure is caused by this bug:
configure:32574: checking for cairo's pthread feature
configure:32685: /usr/bin/gcc-4.2 -o conftest -pipe -O2 -arch i386
-D_REENTRANT -I/opt/local/include -L/opt/local/lib -arch i386
conftest.c -lrt   -lpthread >&5
ld: warning: in /usr/local/lib/librt.a, file was built for unsupported
file format which is not the architecture being linked (i386)

configure:32574: checking for cairo's pthread feature
configure:32685: /usr/bin/gcc-4.2 -o conftest -pipe -O2 -arch x86_64
-D_REENTRANT -I/opt/local/include -L/opt/local/lib -arch x86_64
conftest.c -lrt   -lpthread >&5
ld: warning: in /usr/local/lib/librt.a, file was built for unsupported
file format which is not the architecture being linked (x86_64)

ld is generating a (harmless) warning, but the build system assumes it
is a critical error.

>
> Can you check if it builds using this guide
> http://cairographics.org/end_to_end_build_for_mac_os_x/ ?
>
>>
>> https://trac.macports.org/ticket/31275#comment:7
>>
>> This problem is outside my area of expertise so I don't know what to do
>> other than report it to you. If you need more details it might be best to
>> contact the user who reported the ticket.
>
> The mail is hidden, so this is not so easy to do.
>
>>
>>
>> --
>> cairo mailing list
>> cairo at cairographics.org
>> http://lists.cairographics.org/mailman/listinfo/cairo
>
>
>
> --
> cairo mailing list
> cairo at cairographics.org
> http://lists.cairographics.org/mailman/listinfo/cairo


More information about the cairo mailing list