Skip to content

Commit 069cf04

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 18d4f5c commit 069cf04

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,
@@ -2685,7 +2684,7 @@ int symlink(const char *target, const char *link)
26852684
int len;
26862685

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

config.mak.uname

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -398,8 +398,6 @@ ifeq ($(uname_S),Windows)
398398
NO_GETTEXT = YesPlease
399399
NO_PYTHON = YesPlease
400400
ETAGS_TARGET = ETAGS
401-
NO_INET_PTON = YesPlease
402-
NO_INET_NTOP = YesPlease
403401
NO_POSIX_GOODIES = UnfortunatelyYes
404402
NATIVE_CRLF = YesPlease
405403
DEFAULT_HELP_FORMAT = html
@@ -567,8 +565,6 @@ ifneq (,$(findstring MINGW,$(uname_S)))
567565
NO_REGEX = YesPlease
568566
NO_PYTHON = YesPlease
569567
ETAGS_TARGET = ETAGS
570-
NO_INET_PTON = YesPlease
571-
NO_INET_NTOP = YesPlease
572568
NO_POSIX_GOODIES = UnfortunatelyYes
573569
DEFAULT_HELP_FORMAT = html
574570
COMPAT_CFLAGS += -DNOGDI -Icompat -Icompat/win32

git-compat-util.h

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

157157
#if defined(WIN32) && !defined(__CYGWIN__) /* Both MinGW and MSVC */
158158
# if !defined(_WIN32_WINNT)
159-
# define _WIN32_WINNT 0x0502
159+
# define _WIN32_WINNT 0x0600
160160
# endif
161161
#define WIN32_LEAN_AND_MEAN /* stops windows.h including winsock.h */
162162
#include <winsock2.h>

0 commit comments

Comments
 (0)