Operating System - HP-UX
1834149 Members
3362 Online
110064 Solutions
New Discussion

why I can compile it without using -lpthread?

 
jack_8
Contributor

why I can compile it without using -lpthread?

I wrote a thread programme and compile it without using -lpthread. To my surprise, I compiled it successfully without any warning or error,although it didn't work. I don't know the reason.
2 REPLIES 2
Rita C Workman
Honored Contributor

Re: why I can compile it without using -lpthread?

I think I found the answer, take a look at this:

http://www.cs.columbia.edu/~hgs/os/threads.html

/rcw
jack_8
Contributor

Re: why I can compile it without using -lpthread?

Hi Rita C Workman:
Thank you for your answer. But I really want to know is why it can be compiled successfully without any error. You know because of this, it's very hard to check error!
I got errno is 251 and error message is : Function is not available. I use hp11.0 and aCC 3.25, in my pthread_create manual, there is no place to tell me that I should add pthread library. I am afraid of the same thing happening again on other functions.
In any case, thank you again for your help!
best regards
Jack