Add cuda_dnn option

epel9
Nicolas Chauvet 4 years ago
parent e2830d3e00
commit 8b199e9c33

@ -45,6 +45,7 @@
%global _cuda_version 11.2
%global _cuda_rpm_version 11-2
%global _cuda_prefix /usr/local/cuda-%{_cuda_version}
%bcond_without dnn_cuda
%endif
Name: opencv
@ -81,6 +82,7 @@ BuildRequires: cuda-minimal-build-%{?_cuda_rpm_version}
BuildRequires: pkgconfig(cublas-%{?_cuda_version})
BuildRequires: pkgconfig(cufft-%{?_cuda_version})
BuildRequires: pkgconfig(nppc-%{?_cuda_version})
%{?with_dnn_cuda:BuildRequires: libcudnn8-devel}
}
%{?with_eigen2:BuildRequires: eigen2-devel}
%{?with_eigen3:BuildRequires: eigen3-devel}
@ -301,6 +303,7 @@ install -pm 0644 %{SOURCE4} .cache/ade/
-DCUDA_VERBOSE_BUILD=ON \
-DCUDA_PROPAGATE_HOST_FLAGS=OFF \
-DCUDA_NVCC_FLAGS="-Xcompiler -fPIC" \
%{?with_dnn_cuda:-DOPENCV_DNN_CUDA=ON} \
} \
%{?with_openni: -DWITH_OPENNI=ON } \
%{!?with_xine: -DWITH_XINE=OFF } \

Loading…
Cancel
Save