New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
windows make fail for curl 7.71.1 #5674
Comments
I would guess that mingw needs something more included to get |
Winsock is supposed to define ADDRESS_FAMILY, is that missing from mingw winsock includes? Lines 721 to 732 in 5a1fc8d
/cc @vszakats |
In my copy of @LJWxyz Can you verify the above in your mingw headers? Also, can you try with this patch applied: diff --git a/lib/config-win32.h b/lib/config-win32.h
index 76ee6b1a7..589543ada 100644
--- a/lib/config-win32.h
+++ b/lib/config-win32.h
@@ -723,7 +723,7 @@ Vista
#if !defined(UNIX_PATH_MAX)
/* Replicating logic present in afunix.h of newer Windows 10 SDK versions */
# define UNIX_PATH_MAX 108
-# include <ws2tcpip.h>
+# include <winsock2.h>
/* !checksrc! disable TYPEDEFSTRUCT 1 */
typedef struct sockaddr_un {
ADDRESS_FAMILY sun_family; |
yes it is included already in ws2tcpip.h #if (defined _WINSOCK_H && !defined _WINSOCK2_H) #include <winsock2.h> /** |
Sorry I am quite new to github and this project the snnipet is at
|
Yeah, it's a diff format. |
replaced sadly it doesn't seem to work.Could my path included unnessary binaries? D:\Coding\C\ALLCinone>set PATH=D:\Coding\C\ALLCinone\MinGW64\mingw32\bin;D:\Coding\C\ALLCinone\MinGW64\bin;D:\Coding\C\ALLCinone\MinGW64\x86_64-w64-mingw32\bin;C:\Windows\system32;C:\Windows;.... D:\Coding\C\ALLCinone>cmd /k"set includepath=D:\Coding\C\ALLCinone\MinGW64\include" D:\Coding\C\ALLCinone>cd F:\ProgramSetup\open source\secure\curl-7.71.1 F:\ProgramSetup\open source\secure\curl-7.71.1>mingw32-make mingw32 F:\ProgramSetup\open source\secure\curl-7.71.1> |
According to the mingw-w64 repo, @LJWxyz Is it possible that you're using a mingw environment that may predate that? Can you give us some hints of the mingw version/distro you're using? |
mingw-get-setup.exe ,file ver:0.603.243571 |
@LJWxyz Thank you! It's been long I had a look at the original Interestingly, this release doesn't define May I ask what is your mingw |
I have the same problem gcc 4.7.1 |
Thank you, so this appears to affect classic mingw and/or 10y+ old mingw-w64 environments. One crude solution is to check for a Another option is to check for For the time being, and if circumstances allow it, IMO the best solution is to switch to a |
Please try this patch on various Windows platforms to see if the Unix sockets feature gets correctly enabled/disabled: diff --git a/lib/config-win32.h b/lib/config-win32.h
index 76ee6b1a7..eeaa12655 100644
--- a/lib/config-win32.h
+++ b/lib/config-win32.h
@@ -718,18 +718,22 @@ Vista
#define USE_WIN32_CRYPTO
#endif
+/* On MinGW the ADDRESS_FAMILY typedef was committed alongside LUP_SECURE,
+ so we use it to check for the presence of the typedef. */
+#include <ws2tcpip.h>
+#if !defined(__MINGW32__) || defined(LUP_SECURE)
/* Define to use Unix sockets. */
#define USE_UNIX_SOCKETS
#if !defined(UNIX_PATH_MAX)
/* Replicating logic present in afunix.h of newer Windows 10 SDK versions */
# define UNIX_PATH_MAX 108
-# include <ws2tcpip.h>
/* !checksrc! disable TYPEDEFSTRUCT 1 */
typedef struct sockaddr_un {
ADDRESS_FAMILY sun_family;
char sun_path[UNIX_PATH_MAX];
} SOCKADDR_UN, *PSOCKADDR_UN;
#endif
+#endif
/* ---------------------------------------------------------------- */
/* ADDITIONAL DEFINITIONS */ It tested OK with the latest |
Classic mingw and 10y+ old versions of mingw-w64 don't ship with Windows headers having the typedef necessary for Unix Sockets support, so try detecting these environments to disable this feature. Fixes curl#5674
Classic mingw and 10y+ old versions of mingw-w64 don't ship with Windows headers having the typedef necessary for Unix Sockets support, so try detecting these environments to disable this feature. Ref: https://sourceforge.net/p/mingw-w64/mingw-w64/ci/cf6afc57179a5910621215f8f4037d406892072c/ Fixes curl#5674
I did this
-curl VER-
Did I do something wrong?
The text was updated successfully, but these errors were encountered: