tensorflow: Bazel missing dependency declaration for Eigen
Compilation error that suggests Bazel is not recognizing the Eigen header files. Occurs consistently for me on all versions starting from 21716d8f6e175cd6e8cd97a84e48497574268b0c up until the current master (00726750c9f7dedfc57685c5011e21df3b5b3706).
Environment info
64-bit CentOS / cuda 7.5.18 / cudnn 5.0.5 / bazel 0.2.1 / java 1.8.0_91
Steps to reproduce
Run ./configure and set up compilation with CUDA 7.5 and CuDNN 5.0.
bazel build -c opt --config=cuda //tensorflow/tools/pip_package:build_pip_package
Compiles fine without --config=cuda.
What have you tried?
I ran a git bisect and traced it to 21716d8f6e175cd6e8cd97a84e48497574268b0c. More specifically, it is moving Eigen out of the eigen-eigen-b4fa9622b809 folder that for some reason is causing this. Reverting only these changes from the master makes it compile just fine (see https://github.com/gustavla/tensorflow/commit/058a6517576171bb0c7dcf11ec1aac04bd59aedf). I have so far been unable to fix it while keeping the strip_prefix in.
It suspect it might be a quirk in bazel 0.2.1. It would be great if anyone else running that version can confirm.
Error
The error message (abridged and personal paths removed):
ERROR: /.../tensorflow/core/kernels/BUILD:1527: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/spacetodepth_op_gpu.cu.cc':
'/.../.cache/external/eigen_archive/Eigen/Core'
'/.../.cache/external/eigen_archive/Eigen/src/Core/util/DisableStupidWarnings.h'
'/.../.cache/external/eigen_archive/Eigen/src/Core/util/Macros.h'
...
'/.../.cache/external/eigen_archive/Eigen/src/Core/ArrayWrapper.h'
'/.../.cache/external/eigen_archive/Eigen/src/Core/GlobalFunctions.h'
'/.../.cache/external/eigen_archive/Eigen/src/Core/util/ReenableStupidWarnings.h'.
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 18 (13 by maintainers)
Commits related to this issue
- Pass through -fno-canonical-system-headers This makes the Python crosstool script send -fno-canonical-system-headers to the compiler if it is specified as an argument to the script itself. Without it... — committed to gustavla/tensorflow by gustavla 8 years ago
- Pass through -fno-canonical-system-headers This makes the Python crosstool script send -fno-canonical-system-headers to the compiler if it is specified as an argument to the script itself. Without it... — committed to gustavla/tensorflow by gustavla 8 years ago
- Pass through -fno-canonical-system-headers (#4315) This makes the Python crosstool script send -fno-canonical-system-headers to the compiler if it is specified as an argument to the script itself. ... — committed to tensorflow/tensorflow by gustavla 8 years ago
@martinwicke - What is the relationship between
third_party/eigen3and theeigen_archiveexternal repository?//third_party/eigen3depends on@eigen_archive//:eigen, but I’m not familiar with what the differences between these two packages are.@flybirdx101’s error message seems to be complaining about headers in
//third_party/eigen3and not@eigen_archive:These headers do not seem to be listed in the
hdrsfor thecc_libraryrule inthird_party/eigen3’s BUILD file.@flybirdx101 - can you try adding the following items to the
hdrsglob for thecc_libraryrule inthird_party/eigen3/BUILD?