diff options
Diffstat (limited to 'src/Makefile.m32')
-rw-r--r-- | src/Makefile.m32 | 65 |
1 files changed, 45 insertions, 20 deletions
diff --git a/src/Makefile.m32 b/src/Makefile.m32 index 315cd5c..700cccf 100644 --- a/src/Makefile.m32 +++ b/src/Makefile.m32 @@ -5,7 +5,7 @@ # | (__| |_| | _ <| |___ # \___|\___/|_| \_\_____| # -# Copyright (C) 1999 - 2015, Daniel Stenberg, <daniel@haxx.se>, et al. +# Copyright (C) 1999 - 2017, Daniel Stenberg, <daniel@haxx.se>, et al. # # This software is licensed as described in the file COPYING, which # you should have received as part of this distribution. The terms @@ -22,8 +22,9 @@ ########################################################################### # -## Makefile for building curl.exe with MingW (GCC-3.2 or later) -## and optionally OpenSSL (1.0.2a), libssh2 (1.5), zlib (1.2.8), librtmp (2.4) +## Makefile for building curl.exe with MingW (GCC-3.2 or later or LLVM/Clang) +## and optionally OpenSSL (1.0.2a), libssh2 (1.5), zlib (1.2.8), librtmp (2.4), +## brotli (1.0.1) ## ## Usage: mingw32-make -f Makefile.m32 CFG=-feature1[-feature2][-feature3][...] ## Example: mingw32-make -f Makefile.m32 CFG=-zlib-ssl-sspi-winidn @@ -38,6 +39,10 @@ ifndef ZLIB_PATH ZLIB_PATH = ../../zlib-1.2.8 endif +# Edit the path below to point to the base of your Brotli sources. +ifndef BROTLI_PATH +BROTLI_PATH = ../../brotli-1.0.1 +endif # Edit the path below to point to the base of your OpenSSL package. ifndef OPENSSL_PATH OPENSSL_PATH = ../../openssl-1.0.2a @@ -62,9 +67,9 @@ endif ifndef LIBXML2_PATH LIBXML2_PATH = ../../libxml2-2.9.2 endif -# Edit the path below to point to the base of your libidn package. -ifndef LIBIDN_PATH -LIBIDN_PATH = ../../libidn-1.32 +# Edit the path below to point to the base of your libidn2 package. +ifndef LIBIDN2_PATH +LIBIDN2_PATH = ../../libidn2-2.0.3 endif # Edit the path below to point to the base of your MS IDN package. # Microsoft Internationalized Domain Names (IDN) Mitigation APIs 1.1 @@ -88,12 +93,19 @@ ifndef LIBCARES_PATH LIBCARES_PATH = $(PROOT)/ares endif -CC = $(CROSSPREFIX)gcc +ifeq ($(CURL_CC),) +CURL_CC := $(CROSSPREFIX)gcc +endif +ifeq ($(CURL_AR),) +CURL_AR := $(CROSSPREFIX)ar +endif + +CC = $(CURL_CC) CFLAGS = $(CURL_CFLAG_EXTRAS) -g -O2 -Wall -W CFLAGS += -fno-strict-aliasing # comment LDFLAGS below to keep debug info LDFLAGS = $(CURL_LDFLAG_EXTRAS) $(CURL_LDFLAG_EXTRAS_EXE) -s -AR = $(CROSSPREFIX)ar +AR = $(CURL_AR) RC = $(CROSSPREFIX)windres RCFLAGS = --include-dir=$(PROOT)/include -O COFF STRIP = $(CROSSPREFIX)strip -g @@ -168,9 +180,7 @@ ZLIB = 1 endif ifeq ($(findstring -ssh2,$(CFG)),-ssh2) SSH2 = 1 -ifneq ($(findstring -winssl,$(CFG)),-winssl) SSL = 1 -endif ZLIB = 1 endif ifeq ($(findstring -ssl,$(CFG)),-ssl) @@ -179,8 +189,11 @@ endif ifeq ($(findstring -zlib,$(CFG)),-zlib) ZLIB = 1 endif -ifeq ($(findstring -idn,$(CFG)),-idn) -IDN = 1 +ifeq ($(findstring -brotli,$(CFG)),-brotli) +BROTLI = 1 +endif +ifeq ($(findstring -idn2,$(CFG)),-idn2) +IDN2 = 1 endif ifeq ($(findstring -winidn,$(CFG)),-winidn) WINIDN = 1 @@ -206,6 +219,11 @@ NGHTTP2 = 1 endif INCLUDES = -I. -I../include -I../lib +ifdef SSL + ifdef WINSSL + CFLAGS += -DCURL_WITH_MULTI_SSL + endif +endif ifdef DYN curl_DEPENDENCIES = $(PROOT)/lib/libcurldll.a $(PROOT)/lib/libcurl.dll @@ -274,19 +292,29 @@ ifdef SSL INCLUDES += -I"$(OPENSSL_INCLUDE)" CFLAGS += -DUSE_OPENSSL curl_LDADD += -L"$(OPENSSL_LIBPATH)" $(OPENSSL_LIBS) -else +endif ifdef WINSSL + CFLAGS += -DUSE_SCHANNEL curl_LDADD += -lcrypt32 endif -endif ifdef ZLIB INCLUDES += -I"$(ZLIB_PATH)" CFLAGS += -DHAVE_LIBZ -DHAVE_ZLIB_H curl_LDADD += -L"$(ZLIB_PATH)" -lz endif -ifdef IDN - CFLAGS += -DUSE_LIBIDN - curl_LDADD += -L"$(LIBIDN_PATH)/lib" -lidn +ifdef BROTLI + INCLUDES += -I"$(BROTLI_PATH)/include" + CFLAGS += -DHAVE_BROTLI + curl_LDADD += -L"$(BROTLI_PATH)/lib" + ifdef BROTLI_LIBS + curl_LDADD += $(BROTLI_LIBS) + else + curl_LDADD += -lbrotlidec + endif +endif +ifdef IDN2 + CFLAGS += -DUSE_LIBIDN2 + curl_LDADD += -L"$(LIBIDN2_PATH)/lib" -lidn2 else ifdef WINIDN CFLAGS += -DUSE_WIN32_IDN @@ -307,9 +335,6 @@ ifdef METALINK endif ifdef SSPI CFLAGS += -DUSE_WINDOWS_SSPI - ifdef WINSSL - CFLAGS += -DUSE_SCHANNEL - endif endif ifdef IPV6 CFLAGS += -DENABLE_IPV6 -D_WIN32_WINNT=0x0501 |