Blame view

CMakeLists.txt 1.14 KB
547f6b98   Mahsa Lotfollahi   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
  #Specify the minimum CMake version
  cmake_minimum_required(VERSION 2.8)
  
  #Specify the name of the project			
  project(hypersnakuscules)		
  
  
  #set the module directory
  set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}")
  
  #find OpenCV
  find_package(OpenCV REQUIRED )
  
  #find the STIM library
  find_package(STIM)
  
  #find the CUDA libraries							
  find_package(CUDA REQUIRED)
  
  
  #build the executable in the binary directory on MS Visual Studio
  if ( MSVC )
  	SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY_DEBUG "${OUTPUT_DIRECTORY}")
  	SET( CMAKE_RUNTIME_OUTPUT_DIRECTORY_RELEASE "${OUTPUT_DIRECTORY}")
  endif ( MSVC )
  
  
  #Specify the CUDA include directories for the project			
  include_directories(
  			${STIM_INCLUDE_DIRS}
  			${CUDA_INCLUDE_DIRS}
  			)	
  
  #create an executable from the given CUDA files
  cuda_add_executable(hypersnakuscules
  		      main.cu
  		     )			
  
  #specify any additional libraries here (CUFFT and CUBLAS can be useful)
  target_link_libraries(hypersnakuscules
  		${CUDA_cufft_LIBRARY}
  		${CUDA_cublas_LIBRARY}
  		${OpenCV_LIBS}
  		${CMAKE_THREAD_LIBS_INIT}
  		)
  
  
  message("copying data, it may take some time")
  file(COPY ../../data/3d_dataset DESTINATION .)