From 117ff43cc3ff801265fb47246e6bdec04a91c27f Mon Sep 17 00:00:00 2001 From: Anatoly Baksheev Date: Wed, 15 Jun 2011 08:05:34 +0000 Subject: [PATCH] default cuda target flags changed cuda support is on by default --- CMakeLists.txt | 8 ++++---- modules/gpu/CMakeLists.txt | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 1ea6e6ed0e..ad0d183f9b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -359,7 +359,7 @@ endif() set(WITH_TBB OFF CACHE BOOL "Include Intel TBB support") set(WITH_IPP OFF CACHE BOOL "Include Intel IPP support") set(WITH_EIGEN ON CACHE BOOL "Include Eigen2/Eigen3 support") -set(WITH_CUDA OFF CACHE BOOL "Include NVidia Cuda Runtime support") +set(WITH_CUDA ON CACHE BOOL "Include NVidia Cuda Runtime support") if(WIN32) set(WITH_VIDEOINPUT ON CACHE BOOL "Enable VideoInput support") @@ -762,8 +762,8 @@ if(WITH_CUDA) set(HAVE_CUDA 1) message(STATUS "CUDA detected: " ${CUDA_VERSION}) - set(CUDA_ARCH_BIN "1.1 1.2 1.3 2.0" CACHE STRING "Specify 'real' GPU architectures to build binaries for, BIN(PTX) format is supported") - set(CUDA_ARCH_PTX "1.1 1.3" CACHE STRING "Specify 'virtual' PTX architectures to build PTX intermediate code for") + set(CUDA_ARCH_BIN "1.1 1.2 1.3 2.0 2.1(2.0)" CACHE STRING "Specify 'real' GPU architectures to build binaries for, BIN(PTX) format is supported") + set(CUDA_ARCH_PTX "2.0" CACHE STRING "Specify 'virtual' PTX architectures to build PTX intermediate code for") string(REGEX REPLACE "\\." "" ARCH_BIN_NO_POINTS "${CUDA_ARCH_BIN}") string(REGEX REPLACE "\\." "" ARCH_PTX_NO_POINTS "${CUDA_ARCH_PTX}") @@ -811,7 +811,7 @@ if(WITH_CUDA) set(CUDA_NVCC_FLAGS ${CUDA_NVCC_FLAGS} ${NVCC_FLAGS_EXTRA}) set(OpenCV_CUDA_CC "${NVCC_FLAGS_EXTRA}") - message(STATUS "CUDA NVCC flags: ${CUDA_NVCC_FLAGS}") + message(STATUS "CUDA NVCC target flags: ${CUDA_NVCC_FLAGS}") else() unset(CUDA_ARCH_BIN CACHE) unset(CUDA_ARCH_PTX CACHE) diff --git a/modules/gpu/CMakeLists.txt b/modules/gpu/CMakeLists.txt index e012dda31c..e07f677710 100644 --- a/modules/gpu/CMakeLists.txt +++ b/modules/gpu/CMakeLists.txt @@ -194,10 +194,10 @@ if(BUILD_TESTS AND EXISTS ${CMAKE_CURRENT_SOURCE_DIR}/test) source_group("Src" FILES ${test_hdrs} ${test_srcs}) if(HAVE_CUDA) - include_directories(${CUDA_INCLUDE_DIRS} ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia/core ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia/NPP_staging) - - file(GLOB nvidia "test/nvidia/*.cpp" "test/nvidia/*.h*") - source_group("Src\\NVidia" FILES ${nvidia}) + include_directories(${CUDA_INCLUDE_DIRS} ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia/core ${OpenCV_SOURCE_DIR}/modules/gpu/src/nvidia/NPP_staging) + + file(GLOB nvidia "test/nvidia/*.cpp" "test/nvidia/*.h*") + source_group("Src\\NVidia" FILES ${nvidia}) endif()