This reverts commit 23058f9d. It breaks builds of cuda code somehow in some cases. (cherry picked from commit 6b29aa21)