Fedora Linux Support Community & Resources Center
Old 18th February 2007, 08:24 PM
TerjeG Offline
Registered User
Join Date: Feb 2006
Posts: 4
Question Pthread issues

I'm using Fedora6_64 and I am attempting to write a C program, based on KDevelop, utilizing threads.
I have "included" pthread.h, but when I attempt to build the program I get "undifined reference to pthread_create".
If anyone can shine some light on my problem, I would appreciate it.


Reply With Quote
Old 18th February 2007, 08:45 PM
mwette Offline
Registered User
Join Date: Nov 2005
Location: Los Angeles area
Posts: 887
you need to add "-lpthread" (at least) to the link command
$ gcc -o myprog myprog.c -lpthread
Reply With Quote

issues, pthread

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Display the pthread names? zi_au Using Fedora 2 12th March 2008 08:17 AM
pthread aggravation... Pazuzu Using Fedora 0 21st December 2006 06:21 PM
pthread id and process id ckmun81 Using Fedora 0 20th November 2006 03:32 AM
daemon system call & pthread dudelove Programming & Packaging 3 19th March 2006 08:18 PM
static linking pthread lib afeick Programming & Packaging 10 4th November 2005 02:18 PM

Current GMT-time: 04:17 (Wednesday, 23-08-2017)

TopSubscribe to XML RSS for all Threads in all ForumsFedoraForumDotOrg Archive

All trademarks, and forum posts in this site are property of their respective owner(s).
FedoraForum.org is privately owned and is not directly sponsored by the Fedora Project or Red Hat, Inc.

Privacy Policy | Term of Use | Posting Guidelines | Archive | Contact Us | Founding Members

Powered by vBulletin® Copyright ©2000 - 2012, vBulletin Solutions, Inc.

FedoraForum is Powered by RedHat