/opencl/oclfft

To get this branch, use:
bzr branch http://darksoft.org/webbzr/opencl/oclfft
1 by Matthias Vogelgesang
Initial commit
1
cmake_minimum_required(VERSION 2.6)
2
2 by Matthias Vogelgesang
Install header files and library
3
# --- Build static Apple OpenCL FFT library
1 by Matthias Vogelgesang
Initial commit
4
set(CMAKE_MODULE_PATH ${PROJECT_SOURCE_DIR}/cmake)
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
5
3 by Matthias Vogelgesang
Necessary CFLAG in case someone links with C code
6
set(CMAKE_CXX_FLAGS "-fPIC")
1 by Matthias Vogelgesang
Initial commit
7
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
8
set (MINIMAL_CUDA_VERSION 3.0)
9
find_package(CUDA ${MINIMAL_CUDA_VERSION} QUIET)
10
find_package(ATI QUIET)
1 by Matthias Vogelgesang
Initial commit
11
find_package(OpenCL REQUIRED)
12
13
include_directories(${OPENCL_INCLUDE_DIRS})
14
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
15
add_library(oclfft SHARED
1 by Matthias Vogelgesang
Initial commit
16
    fft_execute.cpp
17
    fft_setup.cpp
18
    fft_kernelstring.cpp)
19
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
20
target_link_libraries(oclfft ${OPENCL_LIBRARIES})
21
22
set_target_properties(oclfft PROPERTIES
23
    VERSION 1.0
24
    SOVERSION 1
25
)
26
2 by Matthias Vogelgesang
Install header files and library
27
# --- Build test application
1 by Matthias Vogelgesang
Initial commit
28
set(CMAKE_C_FLAGS "-std=c99")
29
add_executable(test-oclfft oclfft.c)
30
add_dependencies(test-oclfft oclfft)
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
31
target_link_libraries(test-oclfft oclfft)
2 by Matthias Vogelgesang
Install header files and library
32
33
# --- Install header files and static library
34
install(FILES clFFT.h DESTINATION include)
4 by Suren A. Chilingaryan
Build dynamicly, use OpenCL detection code from PyHST
35
install(TARGETS oclfft LIBRARY DESTINATION lib)