libpthread.so.0 not found trying to link simple app. Library is present in /lib
Hi, I’m trying to build a simple hello world test application using pthreads. This is on a stock SUSE Pro 8.2 installation with all of the latest patches installed. During the link the linker whines that it cannot find libpthread.so.0. I have tried presenting this as -l/lib/libpthread.so.0 (which is where the lib physically resides). This doesn’t change the problem, still no joy with linking the application. I’m probably doing something wrong, but I’ve scanned the web with Google and, while I’ve found similar problems with other libraries mentioned all of those appear to be related to not having the library installed. I haven’t been able to track down a good specific example showing what library to link with, so I’m making the assumption that libpthread.so.0 is the correct one, but it doesn’t appear to be recognized by the linker. Has anyone else encountered this problem, and if so what was the solution? If you can point me to a specific document that details the settings to use to build a “hello world” threaded application on SUSE 8.2 that would be great. Thanks, Burt --- Outgoing mail is certified Virus Free. Checked by AVG anti-virus system (http://www.grisoft.com). Version: 6.0.558 / Virus Database: 350 - Release Date: 1/2/2004
Burt Bicksler wrote :
I have tried presenting this as -l/lib/libpthread.so.0 (which is where the lib physically resides).
Well, this works for me : gcc -g -lpthread -o thread thread.c -- 01110111 01110111 01110111 00101110 01110000 01110010 01110101 01101001 01101101 01100010 01101111 01101111 01101101 00101110 01110100 01101011 <End of message>
participants (2)
-
Burt Bicksler
-
dries