On 25.11.24 01:57, Thomas Munro wrote:
Thanks. I'm going to have a go at adjusting the docs myself so I can get this committed. Invitation remains open for someone closer to the topic to rewrite in a later commit as required for maximum utility to the reader (I'm never going to install MSYS2, or Windows, I just want to blow away as much dead code as possible here as it's in the way of multithreading and other modernisation projects).
Attached is a simple proposal. The section about MinGW can be replaced mostly by "use MSYS2". That's also what CI and the buildfarm uses. Anyone who strays from that can figure it out themselves.
In the Visual Studio section, there was some text that recommended getting flex and bison via MinGW, which seemed clearly outdated. I put in the URL that the CI images use. I don't know if there are other common sources, but that one seems good enough.
From 939a94b524b498cab3a86f6a2e001f61a2e520cd Mon Sep 17 00:00:00 2001 From: Peter Eisentraut <pe...@eisentraut.org> Date: Tue, 26 Nov 2024 17:18:36 +0100 Subject: [PATCH] doc: Update some outdated installation info related to MinGW --- doc/src/sgml/installation.sgml | 60 +++------------------------------- 1 file changed, 5 insertions(+), 55 deletions(-) diff --git a/doc/src/sgml/installation.sgml b/doc/src/sgml/installation.sgml index 5621606f59a..d6986dbd885 100644 --- a/doc/src/sgml/installation.sgml +++ b/doc/src/sgml/installation.sgml @@ -3582,33 +3582,9 @@ <title>MinGW</title> <para> PostgreSQL for Windows can be built using MinGW, a Unix-like build - environment for Microsoft operating systems. - The MinGW build procedure uses the normal build system described in - this chapter. - </para> - - <para> - MinGW, the Unix-like build tools, and MSYS, a collection - of Unix tools required to run shell scripts - like <command>configure</command>, can be downloaded - from <ulink url="http://www.mingw.org/"></ulink>. Neither is - required to run the resulting binaries; they are needed only for - creating the binaries. - </para> - - <para> - To build 64 bit binaries using MinGW, install the 64 bit tool set - from <ulink url="https://mingw-w64.org/"></ulink>, put its bin - directory in the <envar>PATH</envar>, and run - <command>configure</command> with the - <command>--host=x86_64-w64-mingw32</command> option. - </para> - - <para> - After you have everything installed, it is suggested that you - run <application>psql</application> - under <command>CMD.EXE</command>, as the MSYS console has - buffering issues. + environment for Windows. It is recommended to use the <ulink + url="https://www.msys2.org/">MSYS2</ulink> environment for this and also + use that to install any prerequisite packages. </para> <sect3 id="mingw-crash-dumps"> @@ -3838,35 +3814,9 @@ <title>Requirements</title> <productname>Bison</productname> and <productname>Flex</productname> are required. Only <productname>Bison</productname> versions 2.3 and later will work. <productname>Flex</productname> must be version 2.5.35 or later. + Binaries can be downloaded from <ulink + url="https://github.com/lexxmark/winflexbison"></ulink>. </para> - - <para> - Both <productname>Bison</productname> and <productname>Flex</productname> - are included in the <productname>msys</productname> tool suite, available - from <ulink url="http://www.mingw.org/wiki/MSYS"></ulink> as part of the - <productname>MinGW</productname> compiler suite. - </para> - - <para> - You will need to add the directory containing - <filename>flex.exe</filename> and <filename>bison.exe</filename> to the - PATH environment variable. In the case of MinGW, the directory is the - <filename>\msys\1.0\bin</filename> subdirectory of your MinGW - installation directory. - </para> - - <note> - <para> - The Bison distribution from GnuWin32 appears to have a bug that - causes Bison to malfunction when installed in a directory with - spaces in the name, such as the default location on English - installations <filename>C:\Program Files\GnuWin32</filename>. - Consider installing into <filename>C:\GnuWin32</filename> or use the - NTFS short name path to GnuWin32 in your PATH environment setting - (e.g., <filename>C:\PROGRA~1\GnuWin32</filename>). - </para> - </note> - </listitem> </varlistentry> </variablelist> -- 2.47.0