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:
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.
*** Bug 165979 has been marked as a duplicate of this bug. ***