From 4c1b14b59add030cec932647017a4ed05ebb3c6d Mon Sep 17 00:00:00 2001 From: snow flurry Date: Fri, 1 Mar 2024 19:57:27 -0800 Subject: [PATCH] changes for w2k --- lib/config-win32.h | 11 +++++++---- winbuild/MakefileBuild.vc | 25 +++++++++++++++++++++++-- winbuild/gen_resp_file.bat | 7 ++++++- 3 files changed, 36 insertions(+), 7 deletions(-) diff --git a/lib/config-win32.h b/lib/config-win32.h index 89ed1a0..b832b1c 100644 --- a/lib/config-win32.h +++ b/lib/config-win32.h @@ -380,9 +380,10 @@ Vista #endif /* Windows XP is required for freeaddrinfo, getaddrinfo */ -#define HAVE_FREEADDRINFO 1 -#define HAVE_GETADDRINFO 1 -#define HAVE_GETADDRINFO_THREADSAFE 1 +// #define HAVE_FREEADDRINFO 1 +// #define HAVE_GETADDRINFO 1 +// #define HAVE_GETADDRINFO_THREADSAFE 1 +#define Curl_addrinfo_set_port(x,y) /* ---------------------------------------------------------------- */ /* STRUCT RELATED */ @@ -397,12 +398,14 @@ Vista /* Define if struct sockaddr_in6 has the sin6_scope_id member. */ #define HAVE_SOCKADDR_IN6_SIN6_SCOPE_ID 1 +#define ADDRESS_FAMILY USHORT + /* ---------------------------------------------------------------- */ /* LARGE FILE SUPPORT */ /* ---------------------------------------------------------------- */ #if defined(_MSC_VER) && !defined(_WIN32_WCE) -# if (_MSC_VER >= 900) && (_INTEGRAL_MAX_BITS >= 64) +# if (_MSC_VER >= 1500) && (_INTEGRAL_MAX_BITS >= 64) # define USE_WIN32_LARGE_FILES # else # define USE_WIN32_SMALL_FILES diff --git a/winbuild/MakefileBuild.vc b/winbuild/MakefileBuild.vc index 9b16553..ad68efb 100644 --- a/winbuild/MakefileBuild.vc +++ b/winbuild/MakefileBuild.vc @@ -52,7 +52,7 @@ CFLAGS = /I. /I../lib /I../include /nologo /W4 /GX /DWIN32 /YX /FD /c /DBUI !ELSE CC_NODEBUG = $(CC) /O2 /DNDEBUG CC_DEBUG = $(CC) /Od /D_DEBUG /RTC1 /Z7 /LDd -CFLAGS = /I. /I ../lib /I../include /nologo /W4 /EHsc /DWIN32 /FD /c /DBUILDING_LIBCURL +CFLAGS = /I. /I ../lib /I../include /nologo /W4 /EHsc /DWIN32 /FD /c /DBUILDING_LIBCURL /D_WIN32_WINNT=0x0400 /DWINVER=0x0400 /wd4214 !ENDIF LFLAGS = /nologo /machine:$(MACHINE) @@ -201,6 +201,23 @@ MBEDTLS_LIBS = mbedtls.lib mbedcrypto.lib mbedx509.lib !ENDIF +!IFDEF WOLFSSL_PATH +WOLFSSL_INC_DIR = $(WOLFSSL_PATH)\include +WOLFSSL_LIB_DIR = $(WOLFSSL_PATH)\lib +WOLFSSL_LFLAGS = $(WOLFSSL_LFLAGS) "/LIBPATH:$(WOLFSSL_LIB_DIR)" +!ELSE +WOLFSSL_INC_DIR = $(DEVEL_INCLUDE) +WOLFSSL_LIB_DIR = $(DEVEL_LIB) +!ENDIF + +!IF "$(WITH_WOLFSSL)"=="dll" || "$(WITH_WOLFSSL)"=="static" +USE_WOLFSSL = true +WOLFSSL = $(WITH_WOLFSSL) +WOLFSSL_CFLAGS = /DUSE_WOLFSSL /I"$(WOLFSSL_INC_DIR)" +WOLFSSL_LIBS = wolfssl.lib +!ENDIF + + !IFDEF CARES_PATH CARES_INC_DIR = $(CARES_PATH)\include CARES_LIB_DIR = $(CARES_PATH)\lib @@ -363,7 +380,6 @@ USE_SSPI = true SSPI_CFLAGS = $(SSPI_CFLAGS) /DUSE_WINDOWS_SSPI !ENDIF - !IFNDEF USE_SCHANNEL !IF "$(USE_SSL)"=="true" USE_SCHANNEL = false @@ -476,6 +492,11 @@ CFLAGS = $(CFLAGS) $(MBEDTLS_CFLAGS) LFLAGS = $(LFLAGS) $(MBEDTLS_LFLAGS) $(MBEDTLS_LIBS) !ENDIF +!IF "$(USE_WOLFSSL)"=="true" +CFLAGS = $(CFLAGS) $(WOLFSSL_CFLAGS) +LFLAGS = $(LFLAGS) $(WOLFSSL_LFLAGS) $(WOLFSSL_LIBS) +!ENDIF + !IF "$(USE_CARES)"=="true" CFLAGS = $(CFLAGS) $(CARES_CFLAGS) LFLAGS = $(LFLAGS) $(CARES_LFLAGS) $(CARES_LIBS) diff --git a/winbuild/gen_resp_file.bat b/winbuild/gen_resp_file.bat index 6286fd0..950f414 100755 --- a/winbuild/gen_resp_file.bat +++ b/winbuild/gen_resp_file.bat @@ -28,7 +28,12 @@ if exist %OUTFILE% ( ) echo %MACRO_NAME% = \> %OUTFILE% -for %%i in (%*) do echo %DIROBJ%/%%i \>> %OUTFILE% +:loop +IF [%1] == [] GOTO done +echo %DIROBJ%/%1 \>> %OUTFILE% +SHIFT +GOTO loop +:done echo. >> %OUTFILE% :END