<div class="Section1"><p class="MsoNormal">It seems like there isn’t any good reason the perl scripts for the MSVC
builddon’t support readline<p class="MsoNormal"> <p class="MsoNormal">Readline for windows is available as part of the
GnuWin32project. <p class="MsoNormal"> <p class="MsoNormal"><a
href="http://gnuwin32.sourceforge.net/packages/readline.htm">http://gnuwin32.sourceforge.net/packages/readline.htm</a><p
class="MsoNormal"> <pclass="MsoNormal">It normally installs to “c:\Program Files\GnuWin32"<p class="MsoNormal"> <p
class="MsoNormal">I’dupdate the scripts myself, but I’m not a PERL programmer.<p class="MsoNormal">From what I can see,
you’dadd another line to config.pl for readline, and then add some stuff to mkvcbuild.pm for psql to do something
like:<pclass="MsoNormal"> <p class="MsoNormal">if ($solution->{options}->{readline})<p class="MsoNormal"> {<p
class="MsoNormal"> $psql->AddIncludeDir($solution->{options}->{readline} .
'\include');<pclass="MsoNormal">
$psql->AddLibrary($solution->{options}->{readline}. '\lib\readline.lib');<p
class="MsoNormal"> $psql->AddLibrary($solution->{options}->{readline} .
'\lib\history.lib');<pclass="MsoNormal">}<p class="MsoNormal"> <p class="MsoNormal">And something to solution.pm in the
partthat builds pg_config.h that looks something like:<p class="MsoNormal"> <p class="MsoNormal">if
($self->{options}->{readline})<pclass="MsoNormal"> {<p
class="MsoNormal"> print O "#define HAVE_LIBREADLINE 1\n";<p
class="MsoNormal"> print O "#define HAVE_READLINE_READLINE_H 1\n";<p
class="MsoNormal"> print O "#define HAVE_READLINE_HISTORY_H 1\n";<p
class="MsoNormal"> print O "#define USE_READLINE 1\n";<p
class="MsoNormal"> print O "#define USE_READLINE_STATIC 1\n";<p
class="MsoNormal"> }<p class="MsoNormal">(Not sure about the last line).<p
class="MsoNormal"> <pclass="MsoNormal">I don’t know if this is a good idea, but I would think this would make psql more
“user-friendly”on windows.<p class="MsoNormal"> <p class="MsoNormal">Perhaps someone who understands readline and perl
betterthan me might want to take this on?<p class="MsoNormal"> </div>