Bug 162023 - readline should link with termcap or ncurses
Summary: readline should link with termcap or ncurses
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: readline
Version: 4
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Tim Waugh
QA Contact:
URL:
Whiteboard:
: 165979 (view as bug list)
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2005-06-29 07:56 UTC by Oskar Liljeblad
Modified: 2007-11-30 22:11 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2005-06-29 08:31:27 UTC
Type: ---
Embargoed:


Attachments (Terms of Use)

Description Oskar Liljeblad 2005-06-29 07:56:35 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; sv-SE; rv:1.7.8) Gecko/20050511 Firefox/1.0.4

Description of problem:
If you want to compile a program that links with readline you have to link with ncurses or termcap or some other library that provides certain symbols. This is because the readline library so file itself doesn't depend on such a library. I think it would be most useful if it did. I think it is just a matter of putting SHLIB_LIBS=-lncurses after make, but I haven't tested (see patch below).

I crosscompile & crossbuild my RPM packages from a Debian installation. On Debian readline depends on ncurses through the above SHLIB_LIBS

diff -u readline.spec.v0 readline.spec
--- readline.spec.v0    2005-03-02 17:16:00.000000000 +0100
+++ readline.spec       2005-06-29 09:53:25.000000000 +0200
@@ -56,7 +56,7 @@

 %build
 %configure
-make all shared
+make SHLIB_LIBS=-lncurses all shared

 %install
 [ "${RPM_BUILD_ROOT}" != "/" ] && rm -rf ${RPM_BUILD_ROOT}


Version-Release number of selected component (if applicable):
5.0-3

How reproducible:
Always

Steps to Reproduce:
echo "int main() {}" > demo.c
gcc -o demo demo.c -lreadline


Actual Results:  undefined symbols

Expected Results:  no errors

Additional info:

Comment 1 Tim Waugh 2005-06-29 08:31:27 UTC
There are people who need to link against termcap, and people who need to link
against ncurses.  The choice has to be made at compile time for *their* app, not
readline.

Comment 2 Tim Waugh 2005-08-15 15:09:35 UTC
*** Bug 165979 has been marked as a duplicate of this bug. ***


Note You need to log in before you can comment on or make changes to this bug.