Skip to content

Commit

Permalink
Revert "Make tutorial_example_trainer build on Windows with Bazel"
Browse files Browse the repository at this point in the history
  • Loading branch information
rohan100jain authored Oct 15, 2016
1 parent c20da14 commit be3bc47
Show file tree
Hide file tree
Showing 10 changed files with 92 additions and 211 deletions.
6 changes: 0 additions & 6 deletions tensorflow/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ config_setting(
visibility = ["//visibility:public"],
)

config_setting(
name = "windows",
values = {"cpu": "x64_windows_msvc"},
visibility = ["//visibility:public"],
)

config_setting(
name = "ios",
values = {
Expand Down
107 changes: 33 additions & 74 deletions tensorflow/core/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,6 @@ load(
"//tensorflow:tensorflow.bzl",
"if_android",
"if_ios",
"if_not_windows",
"tf_copts",
"tf_cc_test",
"tf_cc_tests",
Expand Down Expand Up @@ -141,7 +140,6 @@ cc_library(
"platform/protobuf.h",
"platform/types.h",
] + glob(tf_additional_proto_hdrs()),
copts = tf_copts(),
deps = [
":protos_all_cc",
"//tensorflow/core/platform/default/build_config:proto_parsing",
Expand Down Expand Up @@ -295,6 +293,8 @@ tf_cuda_library(
"util/example_proto_fast_parsing.h",
"util/example_proto_helper.h",
"util/guarded_philox_random.h",
"util/memmapped_file_system.h",
"util/memmapped_file_system_writer.h",
"util/mirror_pad_mode.h",
"util/padding.h",
"util/port.h",
Expand All @@ -311,13 +311,7 @@ tf_cuda_library(
"util/use_cudnn.h",
"util/util.h",
"util/work_sharder.h",
] + select({
"//tensorflow:windows": [],
"//conditions:default": [
"util/memmapped_file_system.h",
"util/memmapped_file_system_writer.h",
],
}),
],
visibility = ["//visibility:public"],
deps = [":framework_internal"],
)
Expand Down Expand Up @@ -518,6 +512,7 @@ cc_library(
"//tensorflow/core/kernels:control_flow_ops",
"//tensorflow/core/kernels:ctc_ops",
"//tensorflow/core/kernels:data_flow",
"//tensorflow/core/kernels:fact_op",
"//tensorflow/core/kernels:function_ops",
"//tensorflow/core/kernels:image",
"//tensorflow/core/kernels:io",
Expand All @@ -536,11 +531,7 @@ cc_library(
"//tensorflow/core/kernels:string",
"//tensorflow/core/kernels:training_ops",
"//tensorflow/models/embedding:word2vec_kernels",
] + if_not_windows([
"//tensorflow/core/kernels:fact_op",
"//tensorflow/core/kernels:array_not_windows",
"//tensorflow/core/kernels:math_not_windows",
]),
],
)

tf_cuda_library(
Expand Down Expand Up @@ -880,12 +871,12 @@ cc_library(
# Libraries with GPU facilities that are useful for writing kernels.
cc_library(
name = "gpu_lib",
srcs = if_not_windows([
srcs = [
"common_runtime/gpu/gpu_event_mgr.cc",
]),
hdrs = if_not_windows([
],
hdrs = [
"common_runtime/gpu/gpu_event_mgr.h",
]),
],
copts = tf_copts(),
visibility = ["//visibility:public"],
deps = [
Expand All @@ -895,7 +886,8 @@ cc_library(
":lib_internal",
":proto_text",
":protos_all_cc",
] + if_not_windows([":stream_executor"]),
":stream_executor",
],
)

cc_library(
Expand Down Expand Up @@ -955,47 +947,26 @@ tf_proto_library_cc(

cc_library(
name = "lib_internal",
srcs = select({
"//tensorflow:windows": glob(
[
"lib/**/*.h",
"lib/**/*.cc",
"platform/*.h",
"platform/*.cc",
],
exclude = [
"**/*test*",
"platform/**/cuda.h",
"platform/**/stream_executor.h",
"platform/load_library.cc",
],
),
"//conditions:default": glob(
srcs = glob(
[
"lib/**/*.h",
"lib/**/*.cc",
"platform/*.h",
"platform/*.cc",
"platform/profile_utils/**/*.h",
"platform/profile_utils/**/*.cc",
] + tf_additional_lib_srcs(),
exclude =
[
"lib/**/*.h",
"lib/**/*.cc",
"platform/*.h",
"platform/*.cc",
"platform/profile_utils/**/*.h",
"platform/profile_utils/**/*.cc",
],
exclude = [
"**/*test*",
"platform/**/cuda.h",
"platform/**/stream_executor.h",
],
),
}) + tf_additional_lib_srcs(
exclude = [
"**/*test*",
"platform/**/cuda.h",
"platform/**/stream_executor.h",
] +
# Protobuf deps already included through the ":lib_proto_parsing"
# dependency.
tf_additional_proto_srcs(),
] +
# Protobuf deps already included through the ":lib_proto_parsing"
# dependency.
tf_additional_proto_srcs(),
),
hdrs = tf_additional_lib_hdrs() + [
hdrs = glob(tf_additional_lib_hdrs()) + [
"lib/core/blocking_counter.h",
"lib/core/refcount.h",
"lib/gif/gif_io.h",
Expand Down Expand Up @@ -1066,7 +1037,6 @@ tf_version_info_genrule()
cc_library(
name = "version_lib",
srcs = ["util/version_info.cc"],
copts = tf_copts(),
)

tf_cuda_library(
Expand All @@ -1088,18 +1058,8 @@ tf_cuda_library(
"util/reporter.h",
"util/reporter.cc",
"framework/fake_input.*",
"util/memmapped_file_system.*",
"util/memmapped_file_system_writer.*",
],
) + select({
"//tensorflow:windows": [],
"//conditions:default": glob([
"util/memmapped_file_system.h",
"util/memmapped_file_system.cc",
"util/memmapped_file_system_writer.h",
"util/memmapped_file_system_writer.cc",
]),
}),
),
hdrs = [
"framework/op_segment.h",
"framework/rendezvous.h", # only needed for tests
Expand Down Expand Up @@ -1373,7 +1333,7 @@ tf_cuda_library(

tf_cuda_library(
name = "gpu_runtime",
srcs = if_not_windows([
srcs = [
"common_runtime/gpu/gpu_bfc_allocator.cc",
"common_runtime/gpu/gpu_debug_allocator.cc",
"common_runtime/gpu/gpu_device.cc",
Expand All @@ -1385,8 +1345,8 @@ tf_cuda_library(
"common_runtime/gpu/pool_allocator.cc",
"common_runtime/gpu/process_state.cc",
"common_runtime/gpu_device_context.h",
]),
hdrs = if_not_windows([
],
hdrs = [
"common_runtime/gpu/gpu_bfc_allocator.h",
"common_runtime/gpu/gpu_debug_allocator.h",
"common_runtime/gpu/gpu_device.h",
Expand All @@ -1395,7 +1355,7 @@ tf_cuda_library(
"common_runtime/gpu/gpu_util.h",
"common_runtime/gpu/pool_allocator.h",
"common_runtime/gpu/process_state.h",
]),
],
copts = tf_copts(),
linkstatic = 1,
deps = [
Expand All @@ -1407,10 +1367,9 @@ tf_cuda_library(
":lib",
":lib_internal",
":protos_all_cc",
"//third_party/eigen3",
] + if_not_windows([
":stream_executor",
]),
"//third_party/eigen3",
],
alwayslink = 1,
)

Expand Down
Loading

0 comments on commit be3bc47

Please sign in to comment.