Description of problem: i can't build with portaudio: configure:18394: gcc -o conftest -g -O2 conftest.c -lportaudio -lspeex -ltbb >&5 /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_kill' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_create' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_cancel' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_join' collect2: ld returned 1 exit status Version-Release number of selected component (if applicable): portaudio-18.1-8.fc6 How reproducible: try to link :) Steps to Reproduce: 1. 2. 3. Actual results: Expected results: Additional info: My guess: not linked with libpthread
Wow! I had totally forgotten I was the maintainer of portaudio... I recently needed it updated, and thought "I'll have to file a bug against it to get it done". I'll have a look at this when I get a moment. Strange though that no one has noticed this before!
i did some tests, it's v ery strange. To workaround this, i did a export LD_PRELOAD=/lib/libpthread.so.0 and i had the same error. I ldd the file: [root@ruatha TeamBlibbityBlabbity-0.1]# ldd /usr/lib/libportaudio.so linux-gate.so.1 => (0x00cd9000) /lib/libpthread.so.0 (0x002f2000) libc.so.6 => /lib/libc.so.6 (0x00406000) /lib/ld-linux.so.2 (0x80000000) And it's linked with libpthread.. and: [root@ruatha TeamBlibbityBlabbity-0.1]# strings /lib/libpthread.so.0 | grep pthread_kill pthread_kill pthread_kill_other_threads_np So i'm beginning to think about a gcc/ld problem...
[pix@ruatha wynux]$ cat hello.c #include <stdio.h> int main(int argc, char **argv) { printf("Hello world!\n"); return 0; } [pix@ruatha wynux]$ gcc -o hello hello.c -lportaudio /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_kill' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_create' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_cancel' /usr/lib/gcc/i386-redhat-linux/4.1.2/../../../libportaudio.so: undefined reference to `pthread_join' collect2: ld returned 1 exit status
Yeah, but "gcc -o hello hello.c -lportaudio -lpthread" will work. Isn't this just a case of the library not having a nice portaudio-config nor portaudio.pc file to add -lpthread when trying to link against it?
Gasp, i'm sorry, looks like the configure script of the software i want to compile is faulty then. Feel free to close wontfix/invalid :)
Closing NOTABUG, as hopefully it's indeed... not a bug :-)