I am trying to use rules_cuda with a hermetic toolchain (e.g. my cuda stuff is not from the system but from some external workspace, whose BUILD file I am currently writing manually based on the prior art in this repo). Among other issues which are so far easily locally patched out I am wondering why the runtime is a flag instead of part of the toolchain. I think static/dynamic should be a target setting and let toolchain selection decide whether we are using the dynamic or static runtime. Then pass --@rules_cuda//:runtime_static or something to switch to static. (This means we would register 2 toolchains instead of 1).
Without this it is a pain to support multiple toolchains / cuda versions because selecting the cuda version will also always require passing a secondary flag to pick a runtime for it.
I am trying to use
rules_cudawith a hermetic toolchain (e.g. my cuda stuff is not from the system but from some external workspace, whose BUILD file I am currently writing manually based on the prior art in this repo). Among other issues which are so far easily locally patched out I am wondering why the runtime is a flag instead of part of the toolchain. I think static/dynamic should be a target setting and let toolchain selection decide whether we are using the dynamic or static runtime. Then pass--@rules_cuda//:runtime_staticor something to switch to static. (This means we would register 2 toolchains instead of 1).Without this it is a pain to support multiple toolchains / cuda versions because selecting the cuda version will also always require passing a secondary flag to pick a runtime for it.