LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 05-22-2007, 04:44 AM   #1
edgjerp
Member
 
Registered: Dec 2004
Location: Trondheim, Norway
Distribution: kubuntu 10.04
Posts: 308

Rep: Reputation: 31
pthreads error during compile


I am trying to compile spcaview on my Kubuntu system. when I try to 'make', I get a series of errors from the included pthread.h:

Code:
gcc -DUSE_SDL -O2 -DLINUX -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT  -DUSE_SDL -O2 -DLINUX -I/usr/include/SDL -D_GNU_SOURCE=1 -D_REENTRANT   -c -o spcaview.o spcaview.c
In file included from spcaview.c:32:
/usr/include/pthread.h:285: error: conflicting types for ‘pthread_t’
/usr/include/bits/pthreadtypes.h:36: error: previous declaration of ‘pthread_t’ was here
/usr/include/pthread.h:286: error: conflicting types for ‘pthread_attr_t’
/usr/include/bits/pthreadtypes.h:43: error: previous declaration of ‘pthread_attr_t’ was here
/usr/include/pthread.h:287: error: conflicting types for ‘pthread_key_t’
/usr/include/bits/pthreadtypes.h:109: error: previous declaration of ‘pthread_key_t’ was here
/usr/include/pthread.h:289: error: conflicting types for ‘pthread_mutexattr_t’
/usr/include/bits/pthreadtypes.h:79: error: previous declaration of ‘pthread_mutexattr_t’ was here
/usr/include/pthread.h:290: error: conflicting types for ‘pthread_mutex_t’
/usr/include/bits/pthreadtypes.h:73: error: previous declaration of ‘pthread_mutex_t’ was here
/usr/include/pthread.h:291: error: conflicting types for ‘pthread_condattr_t’
/usr/include/bits/pthreadtypes.h:105: error: previous declaration of ‘pthread_condattr_t’ was here
/usr/include/pthread.h:292: error: conflicting types for ‘pthread_cond_t’
/usr/include/bits/pthreadtypes.h:99: error: previous declaration of ‘pthread_cond_t’ was here
/usr/include/pthread.h:293: error: conflicting types for ‘pthread_rwlockattr_t’
/usr/include/bits/pthreadtypes.h:142: error: previous declaration of ‘pthread_rwlockattr_t’ was here
/usr/include/pthread.h:294: error: conflicting types for ‘pthread_rwlock_t’
/usr/include/bits/pthreadtypes.h:136: error: previous declaration of ‘pthread_rwlock_t’ was here
make: *** [spcaview.o] Error 1
I get similar results when trying to build other software that uses pthread.

I have searched both this forum and the web, without really getting anything useful.


Anyone seen similar problems before?
 
Old 05-22-2007, 01:28 PM   #2
studioj
Member
 
Registered: Oct 2006
Posts: 460

Rep: Reputation: 31
uninstall libpthread-dev
 
Old 05-22-2007, 02:20 PM   #3
edgjerp
Member
 
Registered: Dec 2004
Location: Trondheim, Norway
Distribution: kubuntu 10.04
Posts: 308

Original Poster
Rep: Reputation: 31
thanks. it seems I can now build stuff.
 
  


Reply



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 Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
C pthreads -- gcc compile error hussainahsan Programming 4 12-11-2006 12:43 AM
Compile madwifi, ... compile error , how can i do. ERBRMN Linux - Networking 3 03-08-2006 07:56 PM
Winex 3.3, pthreads and error=21 doxxan Linux - Software 3 08-17-2004 02:26 PM
compile error: #error unknown processor family kmack2001 Linux - Newbie 0 02-14-2004 11:52 AM
Kylix doesnt compile pthreads alichan Linux - Software 0 06-24-2003 02:18 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 10:39 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration