"Debarshi 'Rishi' Ray" <[EMAIL PROTECTED]> writes: > I have /usr/include/readline/history.h and /usr/lib/libhistory.so on > my GNU/Linux system, and the former has the prototype for add_history. > However Inetutils does not #include <readline/history.h>, nor does any > of the files in /usr/include/readline #include "history.h". > > So where is the prototype for add_history coming from in Inetutls? > Should not we refer to history.h and/or -lhistory too as just as we do > for readline.h and -lreadline?
Yes, inetutils need to #include history.h and -lhistory to get the function. This seems orthogonal to the readline function: inetutils could use the gnulib module for a readline replacement, and the code can assume that a readline function is always available. The code cannot assume that add_history is available though, and that needs to be protected by appropriate #if's, and configure.ac needs to check for libhistory independently of gnulib. > Secondly, is it possible for add_history to be in libreadline.so > instead of libhistory.so on GNU systems? Or in other terms why should > we check for add_history in both libreadline _and_ libhistory? I don't see why it would help to test for add_history in libreadline. /Simon _______________________________________________ bug-inetutils mailing list [email protected] http://lists.gnu.org/mailman/listinfo/bug-inetutils
