CMakeLists.txt 2.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. cmake_minimum_required(VERSION 2.8)
  2. project (NICELibrary)
  3. include(CheckSymbolExists)
  4. # The version number.
  5. set(NICELibrary_VERSION_MAJOR 1)
  6. set(NICELibrary_VERSION_MINOR 0)
  7. set(CMAKE_VERBOSE_MAKEFILE on)
  8. set(CMAKE_INSTALL_PREFIX ${PROJECT_BINARY_DIR})
  9. set(NICE_BUILD_LIBS_STATIC_SHARED STATIC)
  10. set(NICE_BUILD_PROGS 1)
  11. FIND_PACKAGE(Boost COMPONENTS date_time filesystem)
  12. IF (Boost_FOUND)
  13. message(STATUS "boost-incl-dir: ${Boost_INCLUDE_DIRS}")
  14. INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIRS})
  15. ADD_DEFINITIONS( "-DNICE_BOOST_FOUND" )
  16. ENDIF()
  17. #IF(WIN32)
  18. # MESSAGE(FATAL_ERROR "not yet ready")
  19. #ENDIF(WIN32)
  20. # add the binary tree to the search path for include files
  21. #include_directories ("${PROJECT_BINARY_DIR}")
  22. #SET(CMAKE_USE_RELATIVE_PATHS ON)
  23. #check_symbol_exists("__assert_fail" "assert.h" HAVE_ASSERT_FAIL)
  24. include(cmake/OpenCVUtils.cmake REQUIRE)
  25. include(cmake/NiceModules.cmake REQUIRE)
  26. set(OPENCV_LIB_INSTALL_PATH lib)
  27. INCLUDE_DIRECTORIES(".")
  28. INCLUDE_DIRECTORIES(core)
  29. set(the_module "libnice")
  30. set(NICE_CURR_DIR "${CMAKE_CURRENT_SOURCE_DIR}")
  31. SUBDIRLIST(__listSubDirs "${NICE_CURR_DIR}")
  32. ocv_glob_modules( ${NICE_CURR_DIR} )
  33. # foreach(_curSubdir ${__listSubDirs})
  34. # ocv_get_real_path(__modpath "${NICE_CURR_DIR}/${_curSubdir}/")
  35. # if(EXISTS "${__modpath}/CMakeLists.txt")
  36. # message(STATUS "add module: ${__modpath}")
  37. set(__modpath "${__modpath}/")
  38. message(STATUS "add module: ${__modpath}")
  39. # ocv_glob_modules( ${__modpath} )
  40. # endif()
  41. # endforeach()
  42. #ADD_SUBDIRECTORY(core bin)
  43. # doxygen support
  44. FIND_PROGRAM(DOXYGEN_EXECUTABLE "doxygen")
  45. #cmake code from: https://github.com/hmeyer/dcmtk/blob/master/CMakeLists.txt
  46. # libxml support
  47. # OPTION(WITH_LIBXML "Build with libxml support." OFF)
  48. # FIND_PATH(WITH_LIBXMLINC "include/libxml/parser.h" "${dcmtk_SOURCE_DIR}/../libxml2-2.6.26")
  49. # # libpng support
  50. # OPTION(WITH_LIBPNG "Build with libpng support." ON)
  51. # FIND_PATH(WITH_LIBPNGINC "include/png.h" "${dcmtk_SOURCE_DIR}/../libpng-1.2.8")
  52. # # libtiff support
  53. # OPTION(WITH_LIBTIFF "Build with libtiff support." ON)
  54. # FIND_PATH(WITH_LIBTIFFINC "include/tiff.h" "${dcmtk_SOURCE_DIR}/../tiff-3.7.4")
  55. # # openssl support
  56. # OPTION(WITH_OPENSSL "Build with openssl support." OFF)
  57. # FIND_PATH(WITH_OPENSSLINC "include/openssl/ssl.h" "${dcmtk_SOURCE_DIR}/../openssl-0.9.8a")
  58. # # zlib support
  59. # OPTION(WITH_ZLIB "Build with zlib support." ON)
  60. # FIND_PATH(WITH_ZLIBINC "include/zlib.h" "${dcmtk_SOURCE_DIR}/../zlib-1.2.3")
  61. # add the install targets
  62. #install (TARGETS ImageLabeler DESTINATION bin)
  63. #install (FILES "${PROJECT_BINARY_DIR}/TutorialConfig.h"
  64. # DESTINATION include)