Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT sources DOT redhat DOT com Delivered-To: mailing list cygwin AT sources DOT redhat DOT com Message-ID: <3AA5CC61.17223E62@ece.gatech.edu> Date: Wed, 07 Mar 2001 00:51:29 -0500 From: "Charles S. Wilson" X-Mailer: Mozilla 4.75 [en] (WinNT; U) X-Accept-Language: en MIME-Version: 1.0 To: Markus Hoenicka CC: cygwin AT cygwin DOT com Subject: Re: readline woes References: <15011 DOT 49084 DOT 473000 DOT 44679 AT gargle DOT gargle DOT HOWL> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit I'm not sure if these are related, but you may want to check the following threads. More comments below. libreadline.dll.a missing functions http://www.cygwin.com/ml/cygwin-apps/2001-01/msg00007.html bash calls private readline functions http://www.cygwin.com/ml/cygwin-apps/2001-01/msg00018.html > On a freshly updated box the fileman example of the readline package > works differently if linked statically or dynamically to > libreadline. fileman defines its own completer function, so readline > will try to complete a command name for the first item on the command > line, and it will try to complete filenames for all subsequent items. > > If I link statically, this works as expected. If I link dynamically, > the filename completion still works, but it does no longer try to > complete a command for the first item. Odd. I do not see this difference; both statically linked and dynamically linked fileman.exe (fileman-stat.exe) work identically. > I do not see this problem on a box which is still using cygwin1.dll > version 1.1.7 (and no other packages updated since then). Really odd. Given the same readline distro (readline-4.1-2), changing cygwin shouldn't affect this function, I don't think. > The only > apparent difference is that fileman does not compile out of the box > with the updated tools. The variables rl_readline_name and > rl_attempted_completion_function need to be defined as global > variables in fileman.c to get it link properly. Is this the wrong fix? That is the wrong fix. readline.h (included by fileman.c) already defines: extern READLINE_EXPORT_VAR(CPPFunction *) rl_attempted_completion_function; extern READLINE_EXPORT_VAR(char *) rl_readline_name; Are you sure that you're using the correct -Ddefine's to link dynamically/statically? check /usr/doc/Cygwin/readline-4.1.README. Also, using a freshly updated box (with the since-deprecated gcc-2.95.2-7), and using the readline-4.1-2-src.tar.gz package, fileman builds cleanly ("CC='gcc -mwin32' ./configure --prefix=/usr --with-ncurses") Using gcc-2.95.2-6 (current official version) you don't need to specify CC. > It's not that I badly need fileman, but I use similar code in my own > programs, and fileman is a fairly simple testcase for this problem. --Chuck -- Want to unsubscribe from this list? Check out: http://cygwin.com/ml/#unsubscribe-simple