cmake_minimum_required (VERSION 2.6)

project (voxvision)

set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/Modules")

set (voxvision_VERSION_MAJOR 0)
set (voxvision_VERSION_MINOR 5)
set (voxvision_VERSION ${voxvision_VERSION_MAJOR}.${voxvision_VERSION_MINOR})

set (CMAKE_C_FLAGS_RELEASE "-O2")
set (CMAKE_C_FLAGS_DEBUG "-O0 -g")

find_package (SDL REQUIRED)
find_package (IniParser REQUIRED)

option (SSE_INTRIN "Enable SSE intrinsic")

add_subdirectory (src)

find_package(Doxygen)
if(DOXYGEN_FOUND)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY)
add_custom_target(doc
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating API documentation with Doxygen" VERBATIM
)
endif(DOXYGEN_FOUND)

find_package (CUnit)
if(CUNIT_FOUND)
add_subdirectory (tests)
add_custom_target (test
run-tests
COMMENT "Run tests"
)
endif(CUNIT_FOUND)

install (DIRECTORY examples/ DESTINATION share/voxvision/examples
         FILES_MATCHING PATTERN "*.cfg" PATTERN "*.dat")

cmake_minimum_required (VERSION 2.6)

project (voxvision)

set (CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/Modules")

set (voxvision_VERSION_MAJOR 0)
set (voxvision_VERSION_MINOR 5)
set (voxvision_VERSION ${voxvision_VERSION_MAJOR}.${voxvision_VERSION_MINOR})

set (CMAKE_C_FLAGS_RELEASE "-O2")
set (CMAKE_C_FLAGS_DEBUG "-O0 -g")

find_package (SDL REQUIRED)
find_package (IniParser REQUIRED)

option (SSE_INTRIN "Enable SSE intrinsic")

add_subdirectory (src)

find_package(Doxygen)
if(DOXYGEN_FOUND)
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/Doxyfile.in ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile @ONLY)
add_custom_target(doc
${DOXYGEN_EXECUTABLE} ${CMAKE_CURRENT_BINARY_DIR}/Doxyfile
WORKING_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
COMMENT "Generating API documentation with Doxygen" VERBATIM
)
endif(DOXYGEN_FOUND)

find_package (CUnit)
if(CUNIT_FOUND)
add_subdirectory (tests)
add_custom_target (check
run-tests
COMMENT "Run tests"
)
endif(CUNIT_FOUND)

install (DIRECTORY examples/ DESTINATION share/examples/voxvision
         FILES_MATCHING PATTERN "*.cfg" PATTERN "*.dat")

Install examples in the right place, silent warnings
Install examples in the right place, silent warnings
