Break a dependency from libvecgeom to libvecgeomcuda.
This is a cherry-pick of commits from !866 (closed) to break a dependency between the VecGeom and VecGeomCuda targets:
Due to a misplaced CudaCheckError, libvecgeom depended on libvecgeomcuda even if no cuda features are used.
The cherry-pick is done purely to decouple the parts of !866 (closed) that conflict/override similar changes in !822 (closed). Once cherry-picked, these efforts can be merged into a single MR targeting purely how the CUDA build is done.