Solved

pthread

Posted on 2000-03-22
1
278 Views
Last Modified: 2010-04-22
I wrote a very small program to find out more about pthread's but the program doesn't want to link. I do have the pthread.h header file in the /usr/include directory and compiling works fine, but when gcc starts linking it says : undefinded reference to 'pthread_create'. What's wrong? Which rpm (I'm using RedHat) did I forgot to install this time?
0
Comment
Question by:940961sl
1 Comment
 
LVL 1

Accepted Solution

by:
bcoleman earned 50 total points
ID: 2645557
You need to pass gcc the library pthread.  For example:

gcc test.c -o test -lpthread

Hope this helps!!!
0

Featured Post

How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

Join & Write a Comment

Have you ever been frustrated by having to click seven times in order to retrieve a small bit of information from the web, always the same seven clicks, scrolling down and down until you reach your target? When you know the benefits of the command l…
The purpose of this article is to fix the unknown display problem in Linux Mint operating system. After installing the OS if you see Display monitor is not recognized then we can install "MESA" utilities to fix this problem or we can install additio…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, Just open a new email message.  In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…
This video explains how to create simple products associated to Magento configurable product and offers fast way of their generation with Store Manager for Magento tool.

762 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now