Build libtorch (tag v1.7.0-rc1) in error

tiandekuan: <p>gcc (GCC) 8.4.0<br>
g++ (GCC) 8.4.0<br>
cuda 11.0<br>
cudnn 8.0<br>
cpu  Intel® Core™ i7-9700K CPU @ 3.60GHz<br>
gpu 2080Ti<br>
pytorch git tag   v1.7.0-rc1</p>
<p>build with error:<br>
[3120/3591] Linking CXX executable bin/utility_ops_gpu_test<br>
FAILED: bin/utility_ops_gpu_test<br>
: &amp;&amp; /usr/local/bin/c++ -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -fopenmp -DNDEBUG -DUSE_FBGEMM -DUSE_QNNPACK -DUSE_PYTORCH_QNNPACK -DUSE_XNNPACK -DUSE_VULKAN_WRAPPER -O2 -fPIC -Wno-narrowing -Wall -Wextra -Werror=return-type -Wno-missing-field-initializers -Wno-type-limits -Wno-array-bounds -Wno-unknown-pragmas -Wno-sign-compare -Wno-unused-parameter -Wno-unused-variable -Wno-unused-function -Wno-unused-result -Wno-unused-local-typedefs -Wno-strict-overflow -Wno-strict-aliasing -Wno-error=deprecated-declarations -Wno-stringop-overflow -Wno-psabi -Wno-error=pedantic -Wno-error=redundant-decls -Wno-error=old-style-cast -fdiagnostics-color=always -faligned-new -Wno-unused-but-set-variable -Wno-maybe-uninitialized -fno-math-errno -fno-trapping-math -Werror=format -Wno-stringop-overflow -DHAVE_AVX_CPU_DEFINITION -DHAVE_AVX2_CPU_DEFINITION -O3 -DNDEBUG -DNDEBUG -rdynamic -Wl,-rpath -Wl,/usr/lib/openmpi/lib -Wl,–enable-new-dtags -pthread    -rdynamic caffe2/CMakeFiles/utility_ops_gpu_test.dir/operators/utility_ops_gpu_test.cc.o -o bin/utility_ops_gpu_test  -Wl,-rpath,/usr/local/cuda/lib64:/home/watrix/soft/pytorch/build/lib:  /usr/local/cuda/lib64/libcudart.so  lib/libgtest_main.a  -Wl,–no-as-needed,"/home/watrix/soft/pytorch/build/lib/libtorch.so" -Wl,–as-needed  -Wl,–no-as-needed,"/home/watrix/soft/pytorch/build/lib/libtorch_cpu.so" -Wl,–as-needed  lib/libprotobuf.a  -lmkl_intel_lp64  -lmkl_gnu_thread  -lmkl_core  -fopenmp  -lpthread  -lm  -ldl  lib/libdnnl.a  -ldl  -Wl,–no-as-needed,"/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so" -Wl,–as-needed  lib/libc10_cuda.so  lib/libc10.so  /usr/local/cuda/lib64/libcudart.so  /usr/local/cuda/lib64/libnvToolsExt.so  /usr/local/cuda/lib64/libcufft.so  /usr/local/cuda/lib64/libcurand.so  /usr/local/cuda/lib64/libcublas.so  /usr/local/cuda/lib64/libcudnn.so  lib/libgtest.a  -pthread &amp;&amp; :<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaLongTensor_copy(THCState*, c10::TensorImpl*, c10::TensorImpl*)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaShortTensor_squeeze1d’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaTensor_put(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THNN_CudaHalfClassNLLCriterion_updateGradInput(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, long, c10::TensorImpl*, c10::TensorImpl*, long)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaIntTensor_nDimensionLegacyAll' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THNN_CudaDoubleRReLU_updateOutput(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, double, double, bool, bool, c10::optional<a>at::Generator</a>)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaHalfTensor_resize' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaDoubleStorage_elementSize’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaDoubleTensor_resize4d' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaLongTensor_newContiguous’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaIntTensor_copyIgnoringOverlaps(THCState*, c10::TensorImpl*, c10::TensorImpl*)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCTensor_nDimensionLegacyNoScalars’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaLongTensor_nDimensionLegacyAll' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaTensor_take(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaShortTensor_transpose' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaIntTensor_getDevice(THCState*, c10::TensorImpl const*)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaByteTensor_nDimension' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaByteTensor_resize’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaByteTensor_baddbmm(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, unsigned char, unsigned char)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaCharTensor_fmod(THCState*, c10::TensorImpl*, c10::TensorImpl*, signed char)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaDoubleTensor_mode(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int, int)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaHalfTensor_put(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaTensor_transpose' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaComplexDoubleTensor_newWithStorage1d’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaCharTensor_nDimension' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THNN_CudaHalfSpatialDepthwiseConvolution_accGradParameters(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int, int, int, int, int, int, int, int)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaStorage_set' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaIntTensor_put(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THNN_CudaSpatialConvolutionMM_updateGradInput(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*, int, int, int, int, int, int)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaDoubleTensor_getDevice(THCState*, c10::TensorImpl const*)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCudaByteTensor_indexCopy(THCState*, c10::TensorImpl*, int, c10::TensorImpl*, c10::TensorImpl*)' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaDoubleTensor_multinomialAliasSetup(THCState*, c10::TensorImpl*, c10::TensorImpl*, c10::TensorImpl*)’<br>
/home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to <code>THCStorage_resizeBytes' /home/watrix/soft/pytorch/build/lib/libtorch_cuda.so: undefined reference to </code>THCudaHalfTensor_set’</p>