tensorflow: bazel 0.3.1 compilation failure on master branch

Edit: There is no problem with bazel 0.3.1 and TF 0.9, problem present with master branch and 0.10 RC

Ubuntu 14 x64 MSI GS60 (860M - compute score 3.0)

printf "\nn\ny\n\n7.5\n\n\n\n3.0\n" | ./configure
bazel build -c opt --config=cuda //tensorflow/tools/pip_package:build_pip_package

:

[several minutes of successful compiling]
...
ERROR: /home/ggg/000/tensorflow/tensorflow/core/kernels/BUILD:1515:1: undeclared inclusion(s) in rule '//tensorflow/core/kernels:depth_space_ops_gpu':
this rule is missing dependency declarations for the following files included by 'tensorflow/core/kernels/depthtospace_op_gpu.cu.cc':
  '/usr/local/cuda-7.5/include/cuda_runtime.h'
  '/usr/local/cuda-7.5/include/host_config.h'
  '/usr/local/cuda-7.5/include/builtin_types.h'
  '/usr/local/cuda-7.5/include/device_types.h'
  '/usr/local/cuda-7.5/include/host_defines.h'
  '/usr/local/cuda-7.5/include/driver_types.h'
  '/usr/local/cuda-7.5/include/surface_types.h'
  '/usr/local/cuda-7.5/include/texture_types.h'
  '/usr/local/cuda-7.5/include/vector_types.h'
  '/usr/local/cuda-7.5/include/channel_descriptor.h'
  '/usr/local/cuda-7.5/include/cuda_runtime_api.h'
  '/usr/local/cuda-7.5/include/cuda_device_runtime_api.h'
  '/usr/local/cuda-7.5/include/driver_functions.h'
  '/usr/local/cuda-7.5/include/vector_functions.h'
  '/usr/local/cuda-7.5/include/vector_functions.hpp'
  '/usr/local/cuda-7.5/include/common_functions.h'
  '/usr/local/cuda-7.5/include/math_functions.h'
  '/usr/local/cuda-7.5/include/math_functions.hpp'
  '/usr/local/cuda-7.5/include/math_functions_dbl_ptx3.h'
  '/usr/local/cuda-7.5/include/math_functions_dbl_ptx3.hpp'
  '/usr/local/cuda-7.5/include/cuda_surface_types.h'
  '/usr/local/cuda-7.5/include/cuda_texture_types.h'
  '/usr/local/cuda-7.5/include/device_functions.h'
  '/usr/local/cuda-7.5/include/device_functions.hpp'
  '/usr/local/cuda-7.5/include/device_atomic_functions.h'
  '/usr/local/cuda-7.5/include/device_atomic_functions.hpp'
  '/usr/local/cuda-7.5/include/device_double_functions.h'
  '/usr/local/cuda-7.5/include/device_double_functions.hpp'
  '/usr/local/cuda-7.5/include/sm_20_atomic_functions.h'
  '/usr/local/cuda-7.5/include/sm_20_atomic_functions.hpp'
  '/usr/local/cuda-7.5/include/sm_32_atomic_functions.h'
  '/usr/local/cuda-7.5/include/sm_32_atomic_functions.hpp'
  '/usr/local/cuda-7.5/include/sm_35_atomic_functions.h'
  '/usr/local/cuda-7.5/include/sm_20_intrinsics.h'
  '/usr/local/cuda-7.5/include/sm_20_intrinsics.hpp'
  '/usr/local/cuda-7.5/include/sm_30_intrinsics.h'
  '/usr/local/cuda-7.5/include/sm_30_intrinsics.hpp'
  '/usr/local/cuda-7.5/include/sm_32_intrinsics.h'
  '/usr/local/cuda-7.5/include/sm_32_intrinsics.hpp'
  '/usr/local/cuda-7.5/include/sm_35_intrinsics.h'
  '/usr/local/cuda-7.5/include/surface_functions.h'
  '/usr/local/cuda-7.5/include/surface_functions.hpp'
  '/usr/local/cuda-7.5/include/texture_fetch_functions.h'
  '/usr/local/cuda-7.5/include/texture_fetch_functions.hpp'
  '/usr/local/cuda-7.5/include/texture_indirect_functions.h'
  '/usr/local/cuda-7.5/include/texture_indirect_functions.hpp'
  '/usr/local/cuda-7.5/include/surface_indirect_functions.h'
  '/usr/local/cuda-7.5/include/surface_indirect_functions.hpp'
  '/usr/local/cuda-7.5/include/device_launch_parameters.h'
  '/usr/local/cuda-7.5/include/cuda_fp16.h'
  '/usr/local/cuda-7.5/include/math_constants.h'
  '/usr/local/cuda-7.5/include/curand_kernel.h'
  '/usr/local/cuda-7.5/include/curand.h'
  '/usr/local/cuda-7.5/include/curand_discrete.h'
  '/usr/local/cuda-7.5/include/curand_precalc.h'
  '/usr/local/cuda-7.5/include/curand_mrg32k3a.h'
  '/usr/local/cuda-7.5/include/curand_mtgp32_kernel.h'
  '/usr/local/cuda-7.5/include/cuda.h'
  '/usr/local/cuda-7.5/include/curand_mtgp32.h'
  '/usr/local/cuda-7.5/include/curand_philox4x32_x.h'
  '/usr/local/cuda-7.5/include/curand_globals.h'
  '/usr/local/cuda-7.5/include/curand_uniform.h'
  '/usr/local/cuda-7.5/include/curand_normal.h'
  '/usr/local/cuda-7.5/include/curand_normal_static.h'
  '/usr/local/cuda-7.5/include/curand_lognormal.h'
  '/usr/local/cuda-7.5/include/curand_poisson.h'
  '/usr/local/cuda-7.5/include/curand_discrete2.h'.
nvcc warning : option '--relaxed-constexpr' has been deprecated and replaced by option '--expt-relaxed-constexpr'.
nvcc warning : option '--relaxed-constexpr' has been deprecated and replaced by option '--expt-relaxed-constexpr'.
Target //tensorflow/tools/pip_package:build_pip_package failed to build
Use --verbose_failures to see the command lines of failed build steps.
INFO: Elapsed time: 464.576s, Critical Path: 281.74s

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 31 (20 by maintainers)

Most upvoted comments

I am going offline for the day but I have fixed it with:

$ git diff third_party/gpus/crosstool/CROSSTOOL
diff --git a/third_party/gpus/crosstool/CROSSTOOL b/third_party/gpus/crosstool/CROSSTOOL
index 8db81a9..dfc568b 100644
--- a/third_party/gpus/crosstool/CROSSTOOL
+++ b/third_party/gpus/crosstool/CROSSTOOL
@@ -58,7 +58,7 @@ toolchain {
   # absolute locations and has no remote execution, yet. However, this will need
   # to be fixed, maybe with auto-detection?
   cxx_builtin_include_directory: "/usr/lib/gcc/"
-  cxx_builtin_include_directory: "/usr/local/include"
+  cxx_builtin_include_directory: "/usr/local"
   cxx_builtin_include_directory: "/usr/include"
   tool_path { name: "gcov" path: "/usr/bin/gcov" }

So it means only it missing the include path. #3269 should fix that.

@alexmonroe87 When you run your configure script, are you explicitly setting the CUDA version? If not, you are most likely hitting #3985.