Error building and application that uses OpenCV with CUDA

I’m getting a link error undefined reference to `cv::cuda::StreamAccessor::getStream(cv::cuda::Stream const&)’

I see a StreamAccessor::getStream related symbol in, so I added to the linked libraries in cmake, but I’m still getting the error.

find /workspace/sdk-myapp/opencv-4.2.0/opencv/GCC_9_4_0/local_install/lib -name "" -exec nm --print-file-name --defined-only {} \; | grep getStream | grep StreamAccesso
/workspace/sdk-myapp/opencv-4.2.0/opencv/GCC_9_4_0/local_install/lib/ T _ZN2cv4cuda14StreamAccessor9getStreamERKNS0_6StreamE

Do you get the same error with the latest version of OpenCV? Can you post your CMake command line, configuration output, and build command?