aboutsummaryrefslogtreecommitdiffhomepage
path: root/third_party/curl.BUILD
diff options
context:
space:
mode:
authorGravatar Changming Sun <chasun@microsoft.com>2017-12-09 10:03:43 +0800
committerGravatar drpngx <drpngx@users.noreply.github.com>2017-12-08 18:03:43 -0800
commit826784467ecd0fed8e44645ef1032496fed88ba5 (patch)
tree59b47196eb92232c0110f7b71bc875f3c3e33c17 /third_party/curl.BUILD
parentd3e35f9d8a168d2fdb73b6fa9d7f4b4114cc508d (diff)
Enable GCS filesystem for Windows (#14856)
Diffstat (limited to 'third_party/curl.BUILD')
-rw-r--r--third_party/curl.BUILD26
1 files changed, 23 insertions, 3 deletions
diff --git a/third_party/curl.BUILD b/third_party/curl.BUILD
index e311c7e758..4def6f9489 100644
--- a/third_party/curl.BUILD
+++ b/third_party/curl.BUILD
@@ -10,6 +10,7 @@ CURL_WIN_COPTS = [
"/DHAVE_CONFIG_H",
"/DCURL_DISABLE_FTP",
"/DCURL_DISABLE_NTLM",
+ "/DCURL_DISABLE_PROXY",
"/DHAVE_LIBZ",
"/DHAVE_ZLIB_H",
# Defining _USING_V110_SDK71_ is hackery to defeat curl's incorrect
@@ -23,6 +24,8 @@ CURL_WIN_SRCS = [
"lib/asyn-thread.c",
"lib/inet_ntop.c",
"lib/system_win32.c",
+ "lib/vtls/schannel.c",
+ "lib/idn_win32.c",
]
cc_library(
@@ -276,6 +279,7 @@ cc_library(
"-DCURL_MAX_WRITE_SIZE=65536",
],
}),
+ defines = ["CURL_STATICLIB"],
includes = ["include"],
linkopts = select({
"@org_tensorflow//tensorflow:android": [
@@ -289,10 +293,16 @@ cc_library(
],
"@org_tensorflow//tensorflow:ios": [],
"@org_tensorflow//tensorflow:windows": [
- "-Wl,ws2_32.lib",
+ "-DEFAULTLIB:ws2_32.lib",
+ "-DEFAULTLIB:advapi32.lib",
+ "-DEFAULTLIB:crypt32.lib",
+ "-DEFAULTLIB:Normaliz.lib",
],
"@org_tensorflow//tensorflow:windows_msvc": [
- "-Wl,ws2_32.lib",
+ "-DEFAULTLIB:ws2_32.lib",
+ "-DEFAULTLIB:advapi32.lib",
+ "-DEFAULTLIB:crypt32.lib",
+ "-DEFAULTLIB:Normaliz.lib",
],
"//conditions:default": [
"-lrt",
@@ -438,12 +448,22 @@ genrule(
"# include \"lib/config-win32.h\"",
"# define BUILDING_LIBCURL 1",
"# define CURL_DISABLE_CRYPTO_AUTH 1",
+ "# define CURL_DISABLE_DICT 1",
+ "# define CURL_DISABLE_FILE 1",
+ "# define CURL_DISABLE_GOPHER 1",
"# define CURL_DISABLE_IMAP 1",
"# define CURL_DISABLE_LDAP 1",
"# define CURL_DISABLE_LDAPS 1",
"# define CURL_DISABLE_POP3 1",
"# define CURL_PULL_WS2TCPIP_H 1",
- "# define HTTP_ONLY 1",
+ "# define CURL_DISABLE_SMTP 1",
+ "# define CURL_DISABLE_TELNET 1",
+ "# define CURL_DISABLE_TFTP 1",
+ "# define CURL_PULL_WS2TCPIP_H 1",
+ "# define USE_WINDOWS_SSPI 1",
+ "# define USE_WIN32_IDN 1",
+ "# define USE_SCHANNEL 1",
+ "# define WANT_IDN_PROTOTYPES 1",
"#elif defined(__APPLE__)",
"# define HAVE_FSETXATTR_6 1",
"# define HAVE_SETMODE 1",