I was exploring using Bazel instead of cmake for building a project. Is there something equivalent to "cuda_add_executable" or "cuda_add_library" in cmake?
cc_library doesn't appear to allow ".cu" extensions, so that would require a rename of those files, and looking through the tensorflow repo, it's not entirely clear to me how nvcc might be enabled.
There is no such rule provided by the Bazel team. However you can build one using our extension language. Tensorflow does a bit different. It configure a crosstool and pass it .cc files.