Fail to build a project with object that are template instantiate of thrust::complex

Fail to build a project with object that are template instantiate of thrust::complex.
The log output is :

[yehonatans@srv12 build]$ cmake ..
-- The CXX compiler identification is GNU 11.4.1
-- The CUDA compiler identification is NVIDIA 12.5.40
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Detecting CUDA compiler ABI info
-- Detecting CUDA compiler ABI info - done
-- Check for working CUDA compiler: /usr/local/cuda/bin/nvcc - skipped
-- Detecting CUDA compile features
-- Detecting CUDA compile features - done
-- Found CUDAToolkit: /usr/local/cuda/include (found version "12.5.40") 
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Success
-- Found Threads: TRUE  
-- Configuring done (8.4s)
-- Generating done (0.1s)
-- Build files have been written to: /home/Yehonatans/CLionProjects/CudaTemplateInstansiation/build
[yehonatans@srv12 build]$ make
[ 25%] Building CXX object CMakeFiles/CudaTemplateInstansiation.dir/main.cpp.o
[ 50%] Building CUDA object CMakeFiles/CudaTemplateInstansiation.dir/tt.cu.o
[ 75%] Linking CUDA device code CMakeFiles/CudaTemplateInstansiation.dir/cmake_device_link.o
[100%] Linking CXX executable CudaTemplateInstansiation
/bin/ld: CMakeFiles/CudaTemplateInstansiation.dir/main.cpp.o: in function `main':
main.cpp:(.text+0x8a): undefined reference to `void funca<thrust::THRUST_200400___CUDA_ARCH_LIST___NS::complex<float> >(thrust::THRUST_200400___CUDA_ARCH_LIST___NS::complex<float>)'
/bin/ld: main.cpp:(.text+0xd0): undefined reference to `tt<thrust::THRUST_200400___CUDA_ARCH_LIST___NS::complex<float> >::func(thrust::THRUST_200400___CUDA_ARCH_LIST___NS::complex<float>)'

How to Reproduce:
Build the c++ project without success with Cuda 12.4 or above
proj.zip (1.6 KB)

Expected behavior
The build process will fail

Operating System
Rocky Linux 9 and 8

NVCC version
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2024 NVIDIA Corporation
Built on Wed_Apr_17_19:19:55_PDT_2024
Cuda compilation tools, release 12.5, V12.5.40
Build cuda_12.5.r12.5/compiler.34177558_0

  1. CMake is not a NVIDIA product.
  2. Thrust (at least the CUDA device backend) is generally not usable in a file that ends in .cpp

if you want help here, I suggest demonstrating the problem using nvcc commands directly, not via CMake.