GNU Readline library linking problems

GNU Readline library linking problems

Post by Marcus Nilss » Sat, 28 May 1994 21:55:55



I'm trying to link readline into my program, and it says this:

/lib/libreadline.a(readline.o): Undefined symbol __IO_stdin_ referenced from text segment
/lib/libreadline.a(readline.o): Undefined symbol __IO_stdout_ referenced from text segment
/lib/libreadline.a(readline.o): Undefined symbol __IO_stderr_ referenced from text segment
/lib/libreadline.a(readline.o): Undefined symbol __IO_stderr_ referenced from text segment
/lib/libreadline.a(xmalloc.o): Undefined symbol __IO_stderr_ referenced from text segment

When I compile the examples from the readline archive it says the same
thing, in addition to some other symbols..

Anyone?

--

 
 
 

1. GNU libc extensions (readline) - How to link?

I decided to write some C code using the GNU libc extension, readline.          
But when I compile (even with -lgcc as the last arg on cmd-line):              
poly-render.c:75 (/tmp/cca004401.o): Undefined symbol _getline                  
 referenced text segment                                                        
So I tried "cd /usr/lib; nm lib* | grep readline" and it wasn't there.          
It would seem readline (and other GNU libc extensions) aren't in the            
standard shared libs?  I have Slackware 1.2.1 - soon to be upgraded,            
but that's where my D series came from - 1.1.51 kernel and sundry other        
upgrades too :)save                                                            

Is there a way to include the symbol without linking?  I was able to            
create a .o file without difficulty.  It wasn't in the GCC-FAQ, so              
I ask :)                                                                        

Do Enjoy!                                                                      
--                                                                              
Christopher J. Fearnley       |   UNIX SIG Leader at PACS                      



503 S 44th ST                 |   Linux Advocate                                
Philadelphia PA 1914-3907     |   (215)349-9681                                

2. Which CD-R to buy ?(yes I read the FAQ)

3. GNU readline library in C++

4. Which processor setting for new kernel

5. GNU readline library

6. Ethernet/Cable Internet Questions

7. GNU readlines library

8. I/O permission error ?

9. GNU readline library available

10. GNU readline problem

11. GNU Readline install problem

12. problem building GNU readline 2.1/shared

13. Linking to POSIX library for GNU F77