From 0cc0166a97f95499f0af673f3004d6bb748dc7e4 Mon Sep 17 00:00:00 2001 From: Allen Lavoie Date: Fri, 20 Jul 2018 16:34:46 -0700 Subject: Relax dependency checking for custom op libraries These checks were necessary when we used RTLD_GLOBAL to expose TF symbols to custom ops, since :framework and :lib pulled in implementations. They're now header-only. Ideally we'd switch the checks to framework_internal_impl and lib_internal_impl, but that would require visibility for those rules (thus making it more likely they'd get included in silly places). So this change disables the check for dynamic builds, on the theory that accidentally relying on implementation rules is much more difficult than it was with a static build. Should allow tf_custom_op_libraries to depend on GPU kernels (which depend on core:gpu_lib which depends on :framework). PiperOrigin-RevId: 205472434 --- tensorflow/tensorflow.bzl | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tensorflow/tensorflow.bzl') diff --git a/tensorflow/tensorflow.bzl b/tensorflow/tensorflow.bzl index 954940642b..26970c8cb0 100644 --- a/tensorflow/tensorflow.bzl +++ b/tensorflow/tensorflow.bzl @@ -1359,7 +1359,7 @@ def tf_custom_op_library(name, srcs=[], gpu_srcs=[], deps=[], linkopts=[]): name=name, srcs=srcs, deps=deps + if_cuda(cuda_deps), - data=[name + "_check_deps"], + data=if_static([name + "_check_deps"]), copts=tf_copts(is_external=True), features = ["windows_export_all_symbols"], linkopts=linkopts + select({ -- cgit v1.2.3