Remove temp_workaround_http_archive.

PiperOrigin-RevId: 177230105
This commit is contained in:
Michael Case 2017-11-28 15:45:09 -08:00 committed by TensorFlower Gardener
parent b8969d12f9
commit 5a1e22b753
9 changed files with 51 additions and 89 deletions

View File

@ -57,33 +57,6 @@ def check_version(bazel_version):
fail("\nCurrent Bazel version is {}, expected at least {}\n".format( fail("\nCurrent Bazel version is {}, expected at least {}\n".format(
native.bazel_version, bazel_version)) native.bazel_version, bazel_version))
def _repos_are_siblings():
return Label("@foo//bar").workspace_root.startswith("../")
# Temporary workaround to support including TensorFlow as a submodule until this
# use-case is supported in the next Bazel release.
def _temp_workaround_http_archive_impl(repo_ctx):
repo_ctx.template("BUILD", repo_ctx.attr.build_file, {
"%prefix%": ".." if _repos_are_siblings() else "external",
"%ws%": repo_ctx.attr.repository
}, False)
repo_ctx.download_and_extract(repo_ctx.attr.urls, "", repo_ctx.attr.sha256,
"", repo_ctx.attr.strip_prefix)
if repo_ctx.attr.patch_file != None:
_apply_patch(repo_ctx, repo_ctx.attr.patch_file)
temp_workaround_http_archive = repository_rule(
attrs = {
"build_file": attr.label(),
"repository": attr.string(),
"patch_file": attr.label(default = None),
"urls": attr.string_list(default = []),
"sha256": attr.string(default = ""),
"strip_prefix": attr.string(default = ""),
},
implementation = _temp_workaround_http_archive_impl,
)
# Executes specified command with arguments and calls 'fail' if it exited with # Executes specified command with arguments and calls 'fail' if it exited with
# non-zero code # non-zero code
def _execute_and_check_ret_code(repo_ctx, cmd_and_args): def _execute_and_check_ret_code(repo_ctx, cmd_and_args):
@ -121,8 +94,6 @@ def _patched_http_archive_impl(repo_ctx):
patched_http_archive = repository_rule( patched_http_archive = repository_rule(
attrs = { attrs = {
"patch_file": attr.label(), "patch_file": attr.label(),
"build_file": attr.label(),
"repository": attr.string(),
"urls": attr.string_list(default = []), "urls": attr.string_list(default = []),
"sha256": attr.string(default = ""), "sha256": attr.string(default = ""),
"strip_prefix": attr.string(default = ""), "strip_prefix": attr.string(default = ""),
@ -157,7 +128,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "57ba56c4c243f403ff78f417ff854ef50b9eddf4a610a917b7c95e7fa8553a4b", sha256 = "57ba56c4c243f403ff78f417ff854ef50b9eddf4a610a917b7c95e7fa8553a4b",
strip_prefix = "mklml_lnx_2018.0.20170720", strip_prefix = "mklml_lnx_2018.0.20170720",
build_file = str(Label("//third_party/mkl:mkl.BUILD")), build_file = str(Label("//third_party/mkl:mkl.BUILD")),
repository = tf_repo_name,
) )
if path_prefix: if path_prefix:
@ -292,7 +262,7 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
build_file = str(Label("//third_party:nasm.BUILD")), build_file = str(Label("//third_party:nasm.BUILD")),
) )
temp_workaround_http_archive( native.new_http_archive(
name = "jpeg", name = "jpeg",
urls = [ urls = [
"https://mirror.bazel.build/github.com/libjpeg-turbo/libjpeg-turbo/archive/1.5.1.tar.gz", "https://mirror.bazel.build/github.com/libjpeg-turbo/libjpeg-turbo/archive/1.5.1.tar.gz",
@ -301,7 +271,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "c15a9607892113946379ccea3ca8b85018301b200754f209453ab21674268e77", sha256 = "c15a9607892113946379ccea3ca8b85018301b200754f209453ab21674268e77",
strip_prefix = "libjpeg-turbo-1.5.1", strip_prefix = "libjpeg-turbo-1.5.1",
build_file = str(Label("//third_party/jpeg:jpeg.BUILD")), build_file = str(Label("//third_party/jpeg:jpeg.BUILD")),
repository = tf_repo_name,
) )
native.new_http_archive( native.new_http_archive(
@ -502,7 +471,7 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
build_file = str(Label("//third_party:swig.BUILD")), build_file = str(Label("//third_party:swig.BUILD")),
) )
temp_workaround_http_archive( native.new_http_archive(
name = "curl", name = "curl",
sha256 = "ff3e80c1ca6a068428726cd7dd19037a47cc538ce58ef61c59587191039b2ca6", sha256 = "ff3e80c1ca6a068428726cd7dd19037a47cc538ce58ef61c59587191039b2ca6",
urls = [ urls = [
@ -511,7 +480,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
], ],
strip_prefix = "curl-7.49.1", strip_prefix = "curl-7.49.1",
build_file = str(Label("//third_party:curl.BUILD")), build_file = str(Label("//third_party:curl.BUILD")),
repository = tf_repo_name
) )
# grpc expects //external:protobuf_clib and //external:protobuf_compiler # grpc expects //external:protobuf_clib and //external:protobuf_compiler
@ -575,7 +543,7 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
# TODO(phawkins): currently, this rule uses an unofficial LLVM mirror. # TODO(phawkins): currently, this rule uses an unofficial LLVM mirror.
# Switch to an official source of snapshots if/when possible. # Switch to an official source of snapshots if/when possible.
temp_workaround_http_archive( native.new_http_archive(
name = "llvm", name = "llvm",
urls = [ urls = [
"https://mirror.bazel.build/github.com/llvm-mirror/llvm/archive/9ab4c272cb604a7f947865428c4ef2169fee2100.tar.gz", "https://mirror.bazel.build/github.com/llvm-mirror/llvm/archive/9ab4c272cb604a7f947865428c4ef2169fee2100.tar.gz",
@ -584,7 +552,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "1b1b7d3800a94ca2302e3dd670dbe84238749583027883784b55297059d83da8", sha256 = "1b1b7d3800a94ca2302e3dd670dbe84238749583027883784b55297059d83da8",
strip_prefix = "llvm-9ab4c272cb604a7f947865428c4ef2169fee2100", strip_prefix = "llvm-9ab4c272cb604a7f947865428c4ef2169fee2100",
build_file = str(Label("//third_party/llvm:llvm.BUILD")), build_file = str(Label("//third_party/llvm:llvm.BUILD")),
repository = tf_repo_name,
) )
native.new_http_archive( native.new_http_archive(
@ -650,7 +617,7 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
build_file = str(Label("//third_party/fft2d:fft2d.BUILD")), build_file = str(Label("//third_party/fft2d:fft2d.BUILD")),
) )
temp_workaround_http_archive( native.new_http_archive(
name = "snappy", name = "snappy",
urls = [ urls = [
"https://mirror.bazel.build/github.com/google/snappy/archive/1.1.4.tar.gz", "https://mirror.bazel.build/github.com/google/snappy/archive/1.1.4.tar.gz",
@ -659,10 +626,9 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "2f7504c73d85bac842e893340333be8cb8561710642fc9562fccdd9d2c3fcc94", sha256 = "2f7504c73d85bac842e893340333be8cb8561710642fc9562fccdd9d2c3fcc94",
strip_prefix = "snappy-1.1.4", strip_prefix = "snappy-1.1.4",
build_file = str(Label("//third_party:snappy.BUILD")), build_file = str(Label("//third_party:snappy.BUILD")),
repository = tf_repo_name,
) )
temp_workaround_http_archive( native.new_http_archive(
name = "nccl_archive", name = "nccl_archive",
urls = [ urls = [
"https://mirror.bazel.build/github.com/nvidia/nccl/archive/03d856977ecbaac87e598c0c4bafca96761b9ac7.tar.gz", "https://mirror.bazel.build/github.com/nvidia/nccl/archive/03d856977ecbaac87e598c0c4bafca96761b9ac7.tar.gz",
@ -671,10 +637,9 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "2ca86fb6179ecbff789cc67c836139c1bbc0324ed8c04643405a30bf26325176", sha256 = "2ca86fb6179ecbff789cc67c836139c1bbc0324ed8c04643405a30bf26325176",
strip_prefix = "nccl-03d856977ecbaac87e598c0c4bafca96761b9ac7", strip_prefix = "nccl-03d856977ecbaac87e598c0c4bafca96761b9ac7",
build_file = str(Label("//third_party:nccl.BUILD")), build_file = str(Label("//third_party:nccl.BUILD")),
repository = tf_repo_name,
) )
temp_workaround_http_archive( native.new_http_archive(
name = "aws", name = "aws",
urls = [ urls = [
"https://mirror.bazel.build/github.com/aws/aws-sdk-cpp/archive/1.0.90.tar.gz", "https://mirror.bazel.build/github.com/aws/aws-sdk-cpp/archive/1.0.90.tar.gz",
@ -683,7 +648,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "f599b57aec4f03ad696044dd430b2d201864113937353adc346f53ad47991319", sha256 = "f599b57aec4f03ad696044dd430b2d201864113937353adc346f53ad47991319",
strip_prefix = "aws-sdk-cpp-1.0.90", strip_prefix = "aws-sdk-cpp-1.0.90",
build_file = str(Label("//third_party:aws.BUILD")), build_file = str(Label("//third_party:aws.BUILD")),
repository = tf_repo_name
) )
java_import_external( java_import_external(
@ -711,7 +675,7 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
testonly_ = True, testonly_ = True,
) )
temp_workaround_http_archive( native.new_http_archive(
name = "jemalloc", name = "jemalloc",
urls = [ urls = [
"https://mirror.bazel.build/github.com/jemalloc/jemalloc/archive/4.4.0.tar.gz", "https://mirror.bazel.build/github.com/jemalloc/jemalloc/archive/4.4.0.tar.gz",
@ -720,7 +684,6 @@ def tf_workspace(path_prefix="", tf_repo_name=""):
sha256 = "3c8f25c02e806c3ce0ab5fb7da1817f89fc9732709024e2a81b6b82f7cc792a8", sha256 = "3c8f25c02e806c3ce0ab5fb7da1817f89fc9732709024e2a81b6b82f7cc792a8",
strip_prefix = "jemalloc-4.4.0", strip_prefix = "jemalloc-4.4.0",
build_file = str(Label("//third_party:jemalloc.BUILD")), build_file = str(Label("//third_party:jemalloc.BUILD")),
repository = tf_repo_name,
) )
java_import_external( java_import_external(

16
third_party/aws.BUILD vendored
View File

@ -7,21 +7,21 @@ licenses(["notice"]) # Apache 2.0
exports_files(["LICENSE"]) exports_files(["LICENSE"])
load("@%ws%//third_party:common.bzl", "template_rule") load("@org_tensorflow//third_party:common.bzl", "template_rule")
cc_library( cc_library(
name = "aws", name = "aws",
srcs = select({ srcs = select({
"@%ws%//tensorflow:linux_x86_64": glob([ "@org_tensorflow//tensorflow:linux_x86_64": glob([
"aws-cpp-sdk-core/source/platform/linux-shared/*.cpp", "aws-cpp-sdk-core/source/platform/linux-shared/*.cpp",
]), ]),
"@%ws%//tensorflow:darwin": glob([ "@org_tensorflow//tensorflow:darwin": glob([
"aws-cpp-sdk-core/source/platform/linux-shared/*.cpp", "aws-cpp-sdk-core/source/platform/linux-shared/*.cpp",
]), ]),
"@%ws%//tensorflow:linux_ppc64le": glob([ "@org_tensorflow//tensorflow:linux_ppc64le": glob([
"aws-cpp-sdk-core/source/platform/linux-shared/*.cpp", "aws-cpp-sdk-core/source/platform/linux-shared/*.cpp",
]), ]),
"@%ws%//tensorflow:raspberry_pi_armeabi": glob([ "@org_tensorflow//tensorflow:raspberry_pi_armeabi": glob([
"aws-cpp-sdk-core/source/platform/linux-shared/*.cpp", "aws-cpp-sdk-core/source/platform/linux-shared/*.cpp",
]), ]),
"//conditions:default": [], "//conditions:default": [],
@ -53,17 +53,17 @@ cc_library(
"aws-cpp-sdk-core/include/aws/core/SDKConfig.h", "aws-cpp-sdk-core/include/aws/core/SDKConfig.h",
], ],
defines = select({ defines = select({
"@%ws%//tensorflow:linux_x86_64": [ "@org_tensorflow//tensorflow:linux_x86_64": [
"PLATFORM_LINUX", "PLATFORM_LINUX",
"ENABLE_CURL_CLIENT", "ENABLE_CURL_CLIENT",
"ENABLE_NO_ENCRYPTION", "ENABLE_NO_ENCRYPTION",
], ],
"@%ws%//tensorflow:darwin": [ "@org_tensorflow//tensorflow:darwin": [
"PLATFORM_APPLE", "PLATFORM_APPLE",
"ENABLE_CURL_CLIENT", "ENABLE_CURL_CLIENT",
"ENABLE_NO_ENCRYPTION", "ENABLE_NO_ENCRYPTION",
], ],
"@%ws%//tensorflow:linux_ppc64le": [ "@org_tensorflow//tensorflow:linux_ppc64le": [
"PLATFORM_LINUX", "PLATFORM_LINUX",
"ENABLE_CURL_CLIENT", "ENABLE_CURL_CLIENT",
"ENABLE_NO_ENCRYPTION", "ENABLE_NO_ENCRYPTION",

View File

@ -6,7 +6,7 @@ licenses(["notice"]) # MIT/X derivative license
exports_files(["COPYING"]) exports_files(["COPYING"])
CURL_WIN_COPTS = [ CURL_WIN_COPTS = [
"/I%prefix%/curl/lib", "/Iexternal/curl/lib",
"/DHAVE_CONFIG_H", "/DHAVE_CONFIG_H",
"/DCURL_DISABLE_FTP", "/DCURL_DISABLE_FTP",
"/DCURL_DISABLE_NTLM", "/DCURL_DISABLE_NTLM",
@ -224,14 +224,14 @@ cc_library(
"lib/wildcard.h", "lib/wildcard.h",
"lib/x509asn1.h", "lib/x509asn1.h",
] + select({ ] + select({
"@%ws%//tensorflow:darwin": [ "@org_tensorflow//tensorflow:darwin": [
"lib/vtls/darwinssl.c", "lib/vtls/darwinssl.c",
], ],
"@%ws%//tensorflow:ios": [ "@org_tensorflow//tensorflow:ios": [
"lib/vtls/darwinssl.c", "lib/vtls/darwinssl.c",
], ],
"@%ws%//tensorflow:windows": CURL_WIN_SRCS, "@org_tensorflow//tensorflow:windows": CURL_WIN_SRCS,
"@%ws%//tensorflow:windows_msvc": CURL_WIN_SRCS, "@org_tensorflow//tensorflow:windows_msvc": CURL_WIN_SRCS,
"//conditions:default": [ "//conditions:default": [
"lib/vtls/openssl.c", "lib/vtls/openssl.c",
], ],
@ -248,10 +248,10 @@ cc_library(
"include/curl/typecheck-gcc.h", "include/curl/typecheck-gcc.h",
], ],
copts = select({ copts = select({
"@%ws%//tensorflow:windows": CURL_WIN_COPTS, "@org_tensorflow//tensorflow:windows": CURL_WIN_COPTS,
"@%ws%//tensorflow:windows_msvc": CURL_WIN_COPTS, "@org_tensorflow//tensorflow:windows_msvc": CURL_WIN_COPTS,
"//conditions:default": [ "//conditions:default": [
"-I%prefix%/curl/lib", "-Iexternal/curl/lib",
"-D_GNU_SOURCE", "-D_GNU_SOURCE",
"-DHAVE_CONFIG_H", "-DHAVE_CONFIG_H",
"-DCURL_DISABLE_FTP", "-DCURL_DISABLE_FTP",
@ -261,14 +261,14 @@ cc_library(
"-Wno-string-plus-int", "-Wno-string-plus-int",
], ],
}) + select({ }) + select({
"@%ws%//tensorflow:darwin": [ "@org_tensorflow//tensorflow:darwin": [
"-fno-constant-cfstrings", "-fno-constant-cfstrings",
], ],
"@%ws%//tensorflow:windows": [ "@org_tensorflow//tensorflow:windows": [
# See curl.h for discussion of write size and Windows # See curl.h for discussion of write size and Windows
"/DCURL_MAX_WRITE_SIZE=16384", "/DCURL_MAX_WRITE_SIZE=16384",
], ],
"@%ws%//tensorflow:windows_msvc": [ "@org_tensorflow//tensorflow:windows_msvc": [
# See curl.h for discussion of write size and Windows # See curl.h for discussion of write size and Windows
"/DCURL_MAX_WRITE_SIZE=16384", "/DCURL_MAX_WRITE_SIZE=16384",
], ],
@ -278,20 +278,20 @@ cc_library(
}), }),
includes = ["include"], includes = ["include"],
linkopts = select({ linkopts = select({
"@%ws%//tensorflow:android": [ "@org_tensorflow//tensorflow:android": [
"-pie", "-pie",
], ],
"@%ws%//tensorflow:darwin": [ "@org_tensorflow//tensorflow:darwin": [
"-Wl,-framework", "-Wl,-framework",
"-Wl,CoreFoundation", "-Wl,CoreFoundation",
"-Wl,-framework", "-Wl,-framework",
"-Wl,Security", "-Wl,Security",
], ],
"@%ws%//tensorflow:ios": [], "@org_tensorflow//tensorflow:ios": [],
"@%ws%//tensorflow:windows": [ "@org_tensorflow//tensorflow:windows": [
"-Wl,ws2_32.lib", "-Wl,ws2_32.lib",
], ],
"@%ws%//tensorflow:windows_msvc": [ "@org_tensorflow//tensorflow:windows_msvc": [
"-Wl,ws2_32.lib", "-Wl,ws2_32.lib",
], ],
"//conditions:default": [ "//conditions:default": [
@ -302,9 +302,9 @@ cc_library(
deps = [ deps = [
"@zlib_archive//:zlib", "@zlib_archive//:zlib",
] + select({ ] + select({
"@%ws%//tensorflow:ios": [], "@org_tensorflow//tensorflow:ios": [],
"@%ws%//tensorflow:windows": [], "@org_tensorflow//tensorflow:windows": [],
"@%ws%//tensorflow:windows_msvc": [], "@org_tensorflow//tensorflow:windows_msvc": [],
"//conditions:default": [ "//conditions:default": [
"@boringssl//:ssl", "@boringssl//:ssl",
], ],
@ -312,7 +312,7 @@ cc_library(
) )
CURL_BIN_WIN_COPTS = [ CURL_BIN_WIN_COPTS = [
"/I%prefix%/curl/lib", "/Iexternal/curl/lib",
"/DHAVE_CONFIG_H", "/DHAVE_CONFIG_H",
"/DCURL_DISABLE_LIBCURL_OPTION", "/DCURL_DISABLE_LIBCURL_OPTION",
] ]
@ -406,10 +406,10 @@ cc_binary(
"src/tool_xattr.h", "src/tool_xattr.h",
], ],
copts = select({ copts = select({
"@%ws%//tensorflow:windows": CURL_BIN_WIN_COPTS, "@org_tensorflow//tensorflow:windows": CURL_BIN_WIN_COPTS,
"@%ws%//tensorflow:windows_msvc": CURL_BIN_WIN_COPTS, "@org_tensorflow//tensorflow:windows_msvc": CURL_BIN_WIN_COPTS,
"//conditions:default": [ "//conditions:default": [
"-I%prefix%/curl/lib", "-Iexternal/curl/lib",
"-D_GNU_SOURCE", "-D_GNU_SOURCE",
"-DHAVE_CONFIG_H", "-DHAVE_CONFIG_H",
"-DCURL_DISABLE_LIBCURL_OPTION", "-DCURL_DISABLE_LIBCURL_OPTION",

View File

@ -21,7 +21,7 @@ cc_library(
], ],
hdrs = ["lib/gif_lib.h"], hdrs = ["lib/gif_lib.h"],
defines = select({ defines = select({
#"@%ws%//tensorflow:android": [ #"@org_tensorflow//tensorflow:android": [
":android": [ ":android": [
"S_IREAD=S_IRUSR", "S_IREAD=S_IRUSR",
"S_IWRITE=S_IWUSR", "S_IWRITE=S_IWUSR",

View File

@ -5,7 +5,7 @@ licenses(["notice"]) # BSD
exports_files(["COPYING"]) exports_files(["COPYING"])
load("@%ws%//third_party:common.bzl", "template_rule") load("@org_tensorflow//third_party:common.bzl", "template_rule")
cc_library( cc_library(
name = "jemalloc_headers", name = "jemalloc_headers",
@ -97,10 +97,10 @@ cc_library(
includes = ["include"], includes = ["include"],
# pthread_atfork() is called for PPC. # pthread_atfork() is called for PPC.
linkopts = select({ linkopts = select({
"@%ws%//tensorflow:linux_ppc64le": [ "@org_tensorflow//tensorflow:linux_ppc64le": [
"-lpthread", "-lpthread",
], ],
"@%ws%//tensorflow:linux_x86_64": [ "@org_tensorflow//tensorflow:linux_x86_64": [
"-lpthread", "-lpthread",
], ],
"//conditions:default": [ "//conditions:default": [
@ -208,8 +208,8 @@ genrule(
name = "size_classes_h", name = "size_classes_h",
outs = ["include/jemalloc/internal/size_classes.h"], outs = ["include/jemalloc/internal/size_classes.h"],
cmd = select({ cmd = select({
"@%ws%//tensorflow:linux_ppc64le": "$(location :size_classes_sh) \"3 4\" 3 16 2 >$@", "@org_tensorflow//tensorflow:linux_ppc64le": "$(location :size_classes_sh) \"3 4\" 3 16 2 >$@",
"@%ws%//tensorflow:linux_x86_64": "$(location :size_classes_sh) \"3 4\" 3 12 2 >$@", "@org_tensorflow//tensorflow:linux_x86_64": "$(location :size_classes_sh) \"3 4\" 3 12 2 >$@",
"//conditions:default": "$(location :size_classes_sh) \"3 4\" 3 12 2 >$@", "//conditions:default": "$(location :size_classes_sh) \"3 4\" 3 12 2 >$@",
}), }),
tools = [":size_classes_sh"], tools = [":size_classes_sh"],

View File

@ -5,7 +5,7 @@ licenses(["notice"]) # custom notice-style license, see LICENSE.md
exports_files(["LICENSE.md"]) exports_files(["LICENSE.md"])
load("@%ws%//third_party:common.bzl", "template_rule") load("@org_tensorflow//third_party:common.bzl", "template_rule")
libjpegturbo_nocopts = "-[W]error" libjpegturbo_nocopts = "-[W]error"

View File

@ -60,7 +60,6 @@ mkl_repository = repository_rule(
], ],
attrs = { attrs = {
"build_file": attr.label(), "build_file": attr.label(),
"repository": attr.string(),
"urls": attr.string_list(default = []), "urls": attr.string_list(default = []),
"sha256": attr.string(default = ""), "sha256": attr.string(default = ""),
"strip_prefix": attr.string(default = ""), "strip_prefix": attr.string(default = ""),

View File

@ -44,17 +44,17 @@ cc_library(
"-O3", "-O3",
] + cuda_default_copts(), ] + cuda_default_copts(),
linkopts = select({ linkopts = select({
"@%ws%//tensorflow:android": [ "@org_tensorflow//tensorflow:android": [
"-pie", "-pie",
], ],
"@%ws%//tensorflow:darwin": [ "@org_tensorflow//tensorflow:darwin": [
"-Wl,-framework", "-Wl,-framework",
"-Wl,CoreFoundation", "-Wl,CoreFoundation",
"-Wl,-framework", "-Wl,-framework",
"-Wl,Security", "-Wl,Security",
], ],
"@%ws%//tensorflow:ios": [], "@org_tensorflow//tensorflow:ios": [],
"@%ws%//tensorflow:windows": [ "@org_tensorflow//tensorflow:windows": [
"ws2_32.lib", "ws2_32.lib",
], ],
"//conditions:default": [ "//conditions:default": [

View File

@ -50,8 +50,8 @@ genrule(
"-e 's/@ac_cv_have_stddef_h@/1/g' " + "-e 's/@ac_cv_have_stddef_h@/1/g' " +
"-e 's/@ac_cv_have_stdint_h@/1/g' " + "-e 's/@ac_cv_have_stdint_h@/1/g' " +
select({ select({
"@%ws%//tensorflow:windows": "-e 's/@ac_cv_have_sys_uio_h@/0/g' ", "@org_tensorflow//tensorflow:windows": "-e 's/@ac_cv_have_sys_uio_h@/0/g' ",
"@%ws%//tensorflow:windows_msvc": "-e 's/@ac_cv_have_sys_uio_h@/0/g' ", "@org_tensorflow//tensorflow:windows_msvc": "-e 's/@ac_cv_have_sys_uio_h@/0/g' ",
"//conditions:default": "-e 's/@ac_cv_have_sys_uio_h@/1/g' ", "//conditions:default": "-e 's/@ac_cv_have_sys_uio_h@/1/g' ",
}) + }) +
"-e 's/@SNAPPY_MAJOR@/1/g' " + "-e 's/@SNAPPY_MAJOR@/1/g' " +