Code defining pretty old _WIN32_WINNT values

33 views
Skip to first unread message

Mark Rotteveel

unread,
Jul 30, 2025, 3:25:30 AMJul 30
to firebir...@googlegroups.com
In some places, the code is defining pretty old _WIN32_WINNT values.
Should they? Or should they maybe define higher values or just use the
default (which is 0x0A00 - Windows 10 - in the sdkddkver.h headers on my
machine)?

E.g.

- common/classes/locks.cpp defines _WIN32_WINNT 0x0403 (Windows NT 4 SP
3/ Windows 98)
(Is that whole file still needed at all?)

- common/os/win32/guid.cpp defines _WIN32_WINNT 0x0403 as well
- common/os/win32/mod_loader.cpp defines _WIN32_WINNT 0x0501 (Windows XP)

Maybe these should all be raised to at least 0x0601 (Windows 7), or even
higher, as I don't think current versions will even run on that old an OS.

Mark
--
Mark Rotteveel

Dimitry Sibiryakov

unread,
Jul 30, 2025, 4:29:21 AMJul 30
to firebir...@googlegroups.com
'Mark Rotteveel' via firebird-devel wrote 30.07.2025 9:25:
>
> Maybe these should all be raised to at least 0x0601 (Windows 7), or even higher,
> as I don't think current versions will even run on that old an OS.

AFAIK the only effect of this macro is amount of routines declared in Windows
headers, so if you don't get compilation errors - there is no reason to use them.
Remove them if you wish or leave as is, both cases won't hurt.

--
WBR, SD.

Mark Rotteveel

unread,
Aug 1, 2025, 5:40:51 AMAug 1
to firebir...@googlegroups.com
What is the minimum Windows version we're targeting for Firebird 6?

Because right now, it seems to me the definitions are a bit of a mess:

- Firebird itself does _not_ define _WIN32_WINNT except in those files
mentioned below (those definitions I intend to delete or replace with an
#if that raises a preprocessor #error that the target Windows version is
too old) and in CMakeLists.txt for MinGW (where it defines 0x600
(Windows Vista/Windows Server 2008)).

That basically means that when compiling on the Microsoft tool chain, it
will target the latest version available (e.g. on my machine, 0x0A00
(Windows 10)) due to sdkddkver.h of the Windows API defining that if it
wasn't already defined), which could lead to accidentally using API
calls _not_ available on supported Windows versions (something, IIRC,
that already happened in the past).

- LibCDS currently targets 0x500 (Windows 2000) or 0x501 (Windows
XP/Windows Server 2003), while some of the code in LibCDS will choose -
I assume more efficient - different options for 0x600 (Windows
Vista/Server 2008) and 0x601 (Windows 7), though I'm not sure if those
are relevant for Firebird.

Mark

Paul Reeves

unread,
Aug 1, 2025, 6:16:34 AMAug 1
to firebir...@googlegroups.com
On Fri, 1 Aug 2025 11:40:42 +0200
"'Mark Rotteveel' via firebird-devel" <firebir...@googlegroups.com> wrote:

>What is the minimum Windows version we're targeting for Firebird 6?
>

I think the rule should be whatever is in support by Microsoft at the start of
development of the branch.

Right now that would mean W10 and Windows 2019 are the oldest versions
supported.


Paul
--
Paul Reeves
https://www.ibphoenix.com
Supporting users of Firebird

liviuslivius

unread,
Aug 1, 2025, 9:52:05 AMAug 1
to firebir...@googlegroups.com
Supported by MS vs used by users, are two different things ..

Regards,
Karol Bieniaszewski


-------- Oryginalna wiadomość --------
Od: 'Paul Reeves' via firebird-devel <firebir...@googlegroups.com>
Data: 1.08.2025 12:16 (GMT+01:00)
Temat: Re: [firebird-devel] Code defining pretty old _WIN32_WINNT values

--
Support the ongoing development of Firebird! Consider donating to the Firebird Foundation and help ensure its future. Every contribution makes a difference. Learn more and donate here:
https://www.firebirdsql.org/donate
---
You received this message because you are subscribed to the Google Groups "firebird-devel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to firebird-deve...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/firebird-devel/20250801121626.331c5688%40coutances.fleetriver.com.

Paul Reeves

unread,
Aug 1, 2025, 10:27:53 AMAug 1
to firebir...@googlegroups.com
On Fri, 01 Aug 2025 15:51:55 +0200
"'liviuslivius' via firebird-devel" <firebir...@googlegroups.com> wrote:

>Supported by MS vs used by users, are two different things

We are talking specifically about Firebird 6. Nothing will change for earlier
versions.

Why should the project attempt to support operating systems that are
out of support from the original developer?

Mark Rotteveel

unread,
Aug 2, 2025, 6:41:58 AMAug 2
to firebir...@googlegroups.com
On 01/08/2025 12:16, 'Paul Reeves' via firebird-devel wrote:
> On Fri, 1 Aug 2025 11:40:42 +0200
> "'Mark Rotteveel' via firebird-devel" <firebir...@googlegroups.com> wrote:
>
>> What is the minimum Windows version we're targeting for Firebird 6?
>>
>
> I think the rule should be whatever is in support by Microsoft at the start of
> development of the branch.

OK, but _is_ that the actual rule, or just your opinion on what you'd
like it to be?

> Right now that would mean W10 and Windows 2019 are the oldest versions
> supported.

And what about fbclient.dll?

Mark
--
Mark Rotteveel
Reply all
Reply to author
Forward
0 new messages