d***j 发帖数: 25 | 1 Now I m multithreading a program.
First I try pthread , ihave included the header files and added compiler switches, but compiler always consider no implementation of the pthread methods, "implicit declaration" is reported.
So i turn to thread methods, this time everything ok. Do we need include sone library of pthread when we use it?What we shall do?
Thanks. | h******a 发帖数: 198 | 2 what compiler flag do u add? try gcc -pthread or -lpthread
what platform are u working?
【在 d***j 的大作中提到】 : Now I m multithreading a program. : First I try pthread , ihave included the header files and added compiler switches, but compiler always consider no implementation of the pthread methods, "implicit declaration" is reported. : So i turn to thread methods, this time everything ok. Do we need include sone library of pthread when we use it?What we shall do? : Thanks.
| d***j 发帖数: 25 | 3 i have done it.
Solaris X86 7.0
I set LD_LIBRARY_PATH to include all libs, then pthread works
Thanku
【在 h******a 的大作中提到】 : what compiler flag do u add? try gcc -pthread or -lpthread : what platform are u working?
|
|