| Summary: | x11-libs/cairo-1.14.6 "no mutex implementation found" | ||
|---|---|---|---|
| Product: | Gentoo Linux | Reporter: | Robin Johnson <robbat2> |
| Component: | Current packages | Assignee: | Gentoo X packagers <x11> |
| Status: | RESOLVED TEST-REQUEST | ||
| Severity: | normal | ||
| Priority: | Normal | ||
| Version: | unspecified | ||
| Hardware: | All | ||
| OS: | Linux | ||
| See Also: | https://bugs.freedesktop.org/show_bug.cgi?id=30910 | ||
| Whiteboard: | |||
| Package list: | Runtime testing required: | --- | |
| Attachments: |
build log
cairo-1.14.6-abi_x86_32.x86/config.log cairo-1.14.6-abi_x86_64.amd64/config.log cairo-1.14.6-macos.patch |
||
|
Description
Robin Johnson
2016-04-06 23:10:58 UTC
Created attachment 429796 [details]
cairo-1.14.6-abi_x86_32.x86/config.log
Created attachment 429798 [details]
cairo-1.14.6-abi_x86_64.amd64/config.log
The identical error happens on the 64-bit ABI build. The "-Wl,--build-id" I have in LDFLAGS is the root cause; but the configure script is broken in that case. Indeed, also reproducible with a deprecated flag in LDFLAGS; it causes checks to have a different outcome, therefore it is making false assumptions about the system Am I correct in assuming that this is an upstream problem? 'Cause my desktop installation keeps barfing on compiling cairo and I don't know how to make it stop.
# error "XXX: No mutex implementation found. Cairo will not work with multiple threads. Define CAIRO_NO_MUTEX to 1 to acknowledge and accept this limitation and compile cairo without thread-safety support."
Created attachment 455272 [details, diff]
cairo-1.14.6-macos.patch
This patch is a workaround for this bug on macOS.
I see in Robin's build log: checking for cairo's pthread feature... checking whether cairo's pthread feature could be enabled... no (can't link with -lpthread or -pthread) Today with 1.14.12 and 1.16.0-r2 and LDFLAGS="-Wl,--build-id" I get checking for cairo's pthread feature... checking whether cairo's pthread feature could be enabled... yes and cairo builds. In my config.log I see configure:33994: checking for cairo's pthread feature configure:34105: x86_64-pc-linux-gnu-gcc -o conftest -O2 -march=native -pipe -frecord-gcc-switches -D_REENTRANT -Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed -Wl,--build-id conftest.c -lrt -lm -lpthread >&5 configure:34105: $? = 0 configure:34305: x86_64-pc-linux-gnu-gcc -o conftest -O2 -march=native -pipe -frecord-gcc-switches -D_REENTRANT -Wl,--hash-style=gnu -Wl,-O1 -Wl,--as-needed -Wl,--build-id conftest.c -lrt -lm >&5 /var/tmp/portage/x11-libs/cairo-1.14.12/temp/cckUQeIG.o: In function `test_mutex_attr': conftest.c:(.text+0x86): undefined reference to `pthread_mutexattr_init' conftest.c:(.text+0x95): undefined reference to `pthread_mutexattr_settype' conftest.c:(.text+0xca): undefined reference to `pthread_mutexattr_destroy' collect2: error: ld returned 1 exit status configure:34305: $? = 1 configure: failed program was: [snip] configure:34360: checking whether cairo's pthread feature could be enabled configure:34362: result: yes So I'm wondering if it was actually a binutils change that fixed this. In Robin's config.log I see "ld: warning: Cannot create .note.gnu.build-id section, --build-id ignored." Given that the workaround patch in the upstream bug is about stderr handling, I think this is plausible. Please test and confirm it's working for you now. |