LinuxQuestions.org
View the Most Wanted LQ Wiki articles.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software > Linux - Kernel
User Name
Password
Linux - Kernel This forum is for all discussion relating to the Linux kernel.

Notices

Reply
 
Search this Thread
Old 07-18-2008, 06:38 AM   #1
avinash_ag1985
LQ Newbie
 
Registered: Jul 2008
Distribution: Red Hat
Posts: 7

Rep: Reputation: 0
Problem in installing CLIsh: Configure script unable to find pthread_create function


Hi there.
I'm using CLIsh to build a Cisco-like command line interface for my application. The problem is when I try to install CLIsh. After unzipping the tarball, when i try to do a ./configure(run script to build makefile), I get the following error:

checking for pthread.h... yes
checking for pthread_create in -lpthread... no
configure: error: Cannot find the POSIX threads library

I have checked the library path. The header file exists but somehow the script is not able to link with library. I am accessing a Red Hat 9 system through telnet, with root privileges.

Could someone please help?
Thanks in advance

Last edited by avinash_ag1985; 07-18-2008 at 07:01 AM. Reason: I think I didnt subscribe to the replies to the thread
 
Old 07-20-2008, 05:58 PM   #2
paulsm4
Guru
 
Registered: Mar 2004
Distribution: SusE 8.2
Posts: 5,863
Blog Entries: 1

Rep: Reputation: Disabled
You're logging in as the "root" user with "telnet"? That's pretty scary - look in to SSH.

Meanwhile - you're exactly right. "configure" is telling you that it found a pthreads header (good!), but didn't find a pthreads library (bad).

Why not just (re)install the latest/greatest PThreads RPM?

http://www.redhat.com/docs/manuals/l...hical-rpm.html

Just a thought .. PSM
 
Old 07-21-2008, 07:34 AM   #3
avinash_ag1985
LQ Newbie
 
Registered: Jul 2008
Distribution: Red Hat
Posts: 7

Original Poster
Rep: Reputation: 0
Unhappy

Hi all.
Its all fine now. The script searches the path /usr/local for a .h file, if no other path is specified using --prefix. The path to the -lpthread library must be given explicitly as below:

PTHREAD_LIBS="/usr/lib -lpthread"

This is to be included just before the script searches for the POSIX threads. It will result in a successful compilation but the pthread function will still not be found. It has to be seen if this causes any problems.

However, I now have a new problem. The makefile shows the following error, when command make is given:

g++ -DHAVE_CONFIG_H -I. -I. -std=gnu++98 -g -O2 -MT tinyxml/libtinyxml_la-tinyxml.lo -MD -MP -MF tinyxml/.deps/libtinyxml_la-tinyxml.Tpo -c tinyxml/tinyxml.cpp -fPIC -DPIC -o tinyxml/.libs/libtinyxml_la-tinyxml.o
cc1plus: unrecognized option `-std=gnu++98'
make[1]: *** [tinyxml/libtinyxml_la-tinyxml.lo] Error 1
make[1]: Leaving directory `/home/Avinash/clish-0.7.3'
make: *** [all] Error 2

People, anything?

Last edited by avinash_ag1985; 07-21-2008 at 07:37 AM. Reason: New problem related to this one. Should I start a new thread?
 
Old 07-22-2008, 02:47 PM   #4
knudfl
LQ 5k Club
 
Registered: Jan 2008
Location: Copenhagen, DK
Distribution: pclos2014, Slack14.1 DebWheezy, +50+ other Linux OS, for test only.
Posts: 13,522

Rep: Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503Reputation: 2503
""cc1plus: unrecognized option `-std=gnu++98' ""

Did you read this LQ thread
"Redhat 9.0 has to be stopped at all costs"
http://www.linuxquestions.org/questi...-costs-655491/

I made a test - compile with CLIsh the day you asked : #1
And it will probably compile with no errors on any modern
system. Just './configure && make' ... and it builds.

CLIsh: Not a new program, but all files seems to have got
an overhaul in 2008, not much chance with RH 9, sorry.
But try on a newer OS, and see if the result will fit
the requirements.

Regards
 
  


Reply

Tags
creation, pthreads


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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
passing a class member function to pthread_create. dmail Programming 1 07-29-2006 11:15 AM
./configure problem, unable to find Qt... sometimes J--Lew Linux - Newbie 11 12-13-2005 01:31 PM
my firewall script: unable to understand its function Niceman2005 Linux - Security 3 11-16-2005 07:21 PM
KDevelop's 3.0 configure script can't find my Berkeley DB Oxyd Linux - Software 1 04-11-2004 04:11 PM


All times are GMT -5. The time now is 01:08 PM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration