From: Andres Freund <andres@anarazel.de>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: windows: Set UMDF_USING_NTSTATUS globally, include ntstatus.h
Date: Thu, 29 Sep 2022 05:02:14 +0000
Message-ID: <E1odlgb-0005cg-TE@gemulon.postgresql.org> (raw)
windows: Set UMDF_USING_NTSTATUS globally, include ntstatus.h
We'd like to use precompiled headers on windows to reduce compile times. Right
now we rely on defining UMDF_USING_NTSTATUS before including postgres.h in a few
select places - which doesn't work with precompiled headers. Instead define
it globally.
When UMDF_USING_NTSTATUS is defined we need to explicitly include ntstatus.h,
winternl.h to get a comparable set of symbols. Right now these includes would
be required in a number of non-platform-specific .c files - to avoid that,
include them in win32_port.h. Based on my measurements that doesn't increase
compile times measurably.
Reviewed-by: Thomas Munro <thomas.munro@gmail.com>
Discussion: https://postgr.es/m/20220927011951.j3h4o7n6bhf7dwau@awork3.anarazel.de
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/b8d8a4593a3a2daa5e16e4a3634d9284fe14667f
Modified Files
--------------
src/include/port/win32_port.h | 9 +++++++++
src/include/port/win32ntdll.h | 6 ------
src/port/open.c | 2 --
src/port/win32fdatasync.c | 2 --
src/port/win32ntdll.c | 2 --
src/port/win32stat.c | 2 --
6 files changed, 9 insertions(+), 14 deletions(-)
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-committers@postgresql.org
Cc: andres@anarazel.de
Subject: Re: pgsql: windows: Set UMDF_USING_NTSTATUS globally, include ntstatus.h
In-Reply-To: <E1odlgb-0005cg-TE@gemulon.postgresql.org>
References: <E1odlgb-0005cg-TE@gemulon.postgresql.org>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox