Thread: Building v17 Beta2 on Windows

Building v17 Beta2 on Windows

From
Dominique Devienne
Date:
Hi. I'm using as the go-between for a colleague that's not subscribed
to this ML.

In short, we have Python-based automation scripts to build our 3rd parties.
And the ones we have, that worked fine with v16, do not with v17
beta2, on Windows.
Thus I'm asking for advice as how we should proceed. TIA, --DD

PS: My colleague also mentioned finding posts about a change around a
Meson build???
  Is that now required? Any documentation / release notes regarding
such a change?

PPS: Our intent was to test the new wait-on-socket API discussed with
Tom recently.

----------------8<-------------------- From my colleague

I tried to build the Linux and Windows PostgreSQL 17beta2 devkits.
For that I downloaded the source code from:
https://www.postgresql.org/ftp/source/v17beta2/

And tried to use the python builders we have to build PostgreSQL
devkits in an automated way.

No problem on Linux platform, but the build on Windows platform failed.

We used to proceed this way to build the Windows devkit using VS2022

In the PostgreSQL source folder:
* Cd <PostgreSQL_src_dir>src\tools\msvc
* Create a config.pl file containing a line to locate the OpenSSL devkits
* Run: .\build.bat [DEBUG]

The issue is that, in the PostgreSQL source dir installed from
https://www.postgresql.org/ftp/source/v17beta2/
postgresql-17beta2.tar.gz,
there is no src/tools/msvc folder.

I looked for a Windows 17beta2 package to download, but only saw
Postgresql 16 version:
https://www.postgresql.org/docs/current/install-windows-full.html

There is no mention of Windows OS.
neither in https://www.postgresql.org/download/snapshots/
nor in https://www.postgresql.org/download/windows/

So for the moment, I don’t know how to proceed



Re: Building v17 Beta2 on Windows

From
David Rowley
Date:
On Mon, 5 Aug 2024 at 23:41, Dominique Devienne <ddevienne@gmail.com> wrote:
>   Is that now required? Any documentation / release notes regarding
> such a change?

Yes. The release notes mention:

"Remove the Microsoft Visual Studio-specific PostgreSQL build option
(Michael Paquier)
Meson is now the only available method for Visual Studio builds."

See: https://www.postgresql.org/docs/17/release-17.html

> I looked for a Windows 17beta2 package to download, but only saw
> Postgresql 16 version:
> https://www.postgresql.org/docs/current/install-windows-full.html

https://www.postgresql.org/download/snapshots/ does link to
https://www.enterprisedb.com/products-services-training/pgdevdownload
. I see Windows installers for v17b2.

> So for the moment, I don’t know how to proceed

Meson is now the build system for Windows:
https://www.postgresql.org/docs/17/install-meson.html

David



Re: Building v17 Beta2 on Windows

From
Dominique Devienne
Date:
On Mon, Aug 5, 2024 at 2:26 PM David Rowley <dgrowleyml@gmail.com> wrote:
> Meson is now the only available method for Visual Studio builds."

Thanks David. My colleague figured it out, thanks to your pointers. Cheers, --DD



Re: Building v17 Beta2 on Windows

From
Dominique Devienne
Date:
On Tue, Aug 6, 2024 at 10:53 AM Dominique Devienne <ddevienne@gmail.com> wrote:
> On Mon, Aug 5, 2024 at 2:26 PM David Rowley <dgrowleyml@gmail.com> wrote:
> > Meson is now the only available method for Visual Studio builds."
>
> Thanks David. My colleague figured it out, thanks to your pointers. Cheers, --DD

FYI, we ran into a surprising change, going from using Makefiles in beta2,
to using Meson in beta3, on Linux, for consistency with the Windows build.
The libraries are now in lib64 instead of lib. Yet another change to adapt to.
No big deal, just not 100% backward compatible, that's all. --DD