Files
MINGW-packages/mingw-w64-python/0067-configure.ac-fix-inet_pton-check.patch
2023-02-10 12:56:41 +01:00

33 lines
955 B
Diff

From 0075d72a7e2db6dde04a33dcfd73a4d5737f7a73 Mon Sep 17 00:00:00 2001
From: Christoph Reiter <reiter.christoph@gmail.com>
Date: Thu, 17 Jun 2021 18:52:23 +0530
Subject: [PATCH 067/N] configure.ac: fix inet_pton check
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Co-authored-by: Алексей <alexey.pawlow@gmail.com>
---
configure.ac | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/configure.ac b/configure.ac
index b28492b..dad3868 100644
--- a/configure.ac
+++ b/configure.ac
@@ -4300,10 +4300,14 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM([[
AC_MSG_CHECKING(for inet_pton)
AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[
+#ifdef _WIN32
+#include <ws2tcpip.h>
+#else
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <arpa/inet.h>
+#endif
]], [[void* p = inet_pton]])],
[AC_DEFINE(HAVE_INET_PTON, 1, Define if you have the 'inet_pton' function.)
AC_MSG_RESULT(yes)],