Skip to content

Commit 31a5d68

Browse files
committed
mingw: bump the minimum Windows version to Vista
Quite some time ago, a last plea to the XP users out there who want to see Windows XP support in Git for Windows, asking them to get engaged and help, vanished into the depths of the universe. It is time to codify the ascent by the "silent majority" of XP users, and mark the minimum Windows version required for Git for Windows as Windows Vista. This, incidentally, lets us use quite a few nice new APIs. This also means that we no longer need the inet_pton() and inet_ntop() emulation, and we no longer need to do the PROC_ADDR dance with the `CreateSymbolicLinkW()` function, either. Signed-off-by: Johannes Schindelin <[email protected]>
1 parent 5d8647e commit 31a5d68

File tree

3 files changed

+2
-7
lines changed

3 files changed

+2
-7
lines changed

compat/mingw.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -274,7 +274,6 @@ int mingw_core_config(const char *var, const char *value, void *cb)
274274
}
275275

276276
static DWORD symlink_file_flags = 0, symlink_directory_flags = 1;
277-
DECLARE_PROC_ADDR(kernel32.dll, BOOLEAN, CreateSymbolicLinkW, LPCWSTR, LPCWSTR, DWORD);
278277

279278
enum phantom_symlink_result {
280279
PHANTOM_SYMLINK_RETRY,
@@ -2687,7 +2686,7 @@ int symlink(const char *target, const char *link)
26872686
int len;
26882687

26892688
/* fail if symlinks are disabled or API is not supported (WinXP) */
2690-
if (!has_symlinks || !INIT_PROC_ADDR(CreateSymbolicLinkW)) {
2689+
if (!has_symlinks) {
26912690
errno = ENOSYS;
26922691
return -1;
26932692
}

config.mak.uname

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -399,8 +399,6 @@ ifeq ($(uname_S),Windows)
399399
NO_GETTEXT = YesPlease
400400
NO_PYTHON = YesPlease
401401
ETAGS_TARGET = ETAGS
402-
NO_INET_PTON = YesPlease
403-
NO_INET_NTOP = YesPlease
404402
NO_POSIX_GOODIES = UnfortunatelyYes
405403
NATIVE_CRLF = YesPlease
406404
DEFAULT_HELP_FORMAT = html
@@ -568,8 +566,6 @@ ifneq (,$(findstring MINGW,$(uname_S)))
568566
NO_REGEX = YesPlease
569567
NO_PYTHON = YesPlease
570568
ETAGS_TARGET = ETAGS
571-
NO_INET_PTON = YesPlease
572-
NO_INET_NTOP = YesPlease
573569
NO_POSIX_GOODIES = UnfortunatelyYes
574570
DEFAULT_HELP_FORMAT = html
575571
COMPAT_CFLAGS += -DNOGDI -Icompat -Icompat/win32

git-compat-util.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@
173173

174174
#if defined(WIN32) && !defined(__CYGWIN__) /* Both MinGW and MSVC */
175175
# if !defined(_WIN32_WINNT)
176-
# define _WIN32_WINNT 0x0502
176+
# define _WIN32_WINNT 0x0600
177177
# endif
178178
#define WIN32_LEAN_AND_MEAN /* stops windows.h including winsock.h */
179179
#include <winsock2.h>

0 commit comments

Comments
 (0)