MXNet GPU build on CPU machine fails #15548
Description
Post PR #15449 , when trying to build mxnet with GPU support on a CPU instance fails, with the following error
Running: OpWrapperGenerator.py
terminate called after throwing an instance of 'dmlc::Error'
what(): [00:10:08]include/mxnet/base.h:427: Check failed: e == cudaSuccess (35 vs. 0) : CUDA: CUDA driver version is insufficient for CUDA runtime version
Stack trace:
[bt] (0) build/lib/libmxnet.so(dmlc::LogMessageFatal::~LogMessageFatal()+0x25) [0x7fcf63bb2793]
[bt] (1) build/lib/libmxnet.so(mxnet::Context::GetGPUCount()+0x11b) [0x7fcf66d39325]
[bt] (2) build/lib/libmxnet.so(+0x5ebcfaa) [0x7fcf66df5faa]
[bt] (3) /build/lib/libmxnet.so(+0x5ebd180) [0x7fcf66df6180]
[bt] (4) build/lib/libmxnet.so(+0x5ebd1b7) [0x7fcf66df61b7]
[bt] (5) /lib64/ld-linux-x86-64.so.2(+0xe9cf) [0x7fcfd1f419cf]
[bt] (6) /lib64/ld-linux-x86-64.so.2(+0x131f5) [0x7fcfd1f461f5]
[bt] (7) /lib64/ld-linux-x86-64.so.2(+0xe5e6) [0x7fcfd1f415e6]
[bt] (8) /lib64/ld-linux-x86-64.so.2(+0x1299a) [0x7fcfd1f4599a]
The cmake setting is as follows
cmake \
-DUSE_OPENCV=${USE_OPENCV:-ON}\
-DUSE_OPENMP=ON\
-DUSE_CUDA=${USE_CUDA:-ON}\
-DUSE_CUDNN=${USE_CUDA:-ON}\
-DUSE_LAPACK=OFF\
-DUSE_MKL_IF_AVAILABLE=ON\
-DUSE_MKLML_MKL=OFF\
-DUSE_MKLDNN=${USE_MKLDNN:-ON}\
-DUSE_SSE=ON\
-DUSE_GPERFTOOLS=OFF\
-DUSE_JEMALLOC=${USE_JEMALLOC:-ON}\
-DUSE_PROFILER=${USE_PROFILER:-ON}\
-DUSE_DIST_KVSTORE=${USE_DIST_KVSTORE:-ON}\
-DUSE_CPP_PACKAGE=ON\
-DCMAKE_BUILD_TYPE=$CMAKE_BUILD_TYPE \
-DCUDA_ARCH_NAME=Manual\
-DCUDA_ARCH_BIN=37,70,75\
-DCUDA_ARCH_PTX=70,75 \
-DINSTALL_PYTHON_VERSIONS="${PYTHON_VERSIONS:-2.7;3.4;3.5;3.6}"\
-DENABLE_CUDA_RTC=${ENABLE_CUDA_RTC:-OFF}\
-DUSE_SIGNAL_HANDLER=OFF\
-DUSE_NCCL=${USE_NCCL:-OFF}
cmake cpp_package_op_h