mirror of
https://git.postgresql.org/git/postgresql.git
synced 2026-02-13 09:57:02 +08:00
The attached patch enables PostgreSQL CVS to build cleanly under Cygwin
when built against readline 4.2. Specifically, it handles the deprecation
of
filename_completion_function()
with preference for
rl_filename_completion_function()
Although, I was motivated by Cygwin support, IMO this patch is appropriate
for all platforms. To quote from the readline source:
#if 0
/* Backwards compatibility (compat.c). These will go away sometime. */
...
extern READLINE_EXPORT(char, *filename_completion_function) ...
#endif
Note that this patch is modeled after the one by Peter Eisentraut for
completion_matches():
http://www.ca.postgresql.org/~petere/readline42.html
I tested this patch under the following environments:
Cygwin with readline 4.1
Cygwin with readline 4.2
Linux with readline 2.2.1
Linux with readline 4.2
and it behaved as expected.
Jason Tishler
This commit is contained in:
@ -8,7 +8,7 @@
|
||||
* or in config.h afterwards. Of course, if you edit config.h, then your
|
||||
* changes will be overwritten the next time you run configure.
|
||||
*
|
||||
* $Id: config.h.in,v 1.165 2001/06/02 18:25:18 petere Exp $
|
||||
* $Id: config.h.in,v 1.166 2001/06/11 22:12:48 momjian Exp $
|
||||
*/
|
||||
|
||||
#ifndef CONFIG_H
|
||||
@ -589,6 +589,9 @@ extern int fdatasync(int fildes);
|
||||
/* Set to 1 if you have rl_completion_matches */
|
||||
#undef HAVE_RL_COMPLETION_MATCHES
|
||||
|
||||
/* Set to 1 if you have rl_filename_completion_function */
|
||||
#undef HAVE_RL_FILENAME_COMPLETION_FUNCTION
|
||||
|
||||
/* Set to 1 if you have getopt_long() (GNU long options) */
|
||||
#undef HAVE_GETOPT_LONG
|
||||
|
||||
|
||||
Reference in New Issue
Block a user