CMakeLists.txt 1.1 KB

123456789101112131415161718192021222324252627282930
  1. project(quirc)
  2. set(CURR_INCLUDE_DIR "${CMAKE_CURRENT_LIST_DIR}/include")
  3. set_property(GLOBAL PROPERTY QUIRC_INCLUDE_DIR ${CURR_INCLUDE_DIR})
  4. ocv_include_directories(${CURR_INCLUDE_DIR})
  5. file(GLOB_RECURSE quirc_headers RELATIVE "${CMAKE_CURRENT_LIST_DIR}" "include/*.h")
  6. file(GLOB_RECURSE quirc_sources RELATIVE "${CMAKE_CURRENT_LIST_DIR}" "src/*.c")
  7. add_library(${PROJECT_NAME} STATIC ${OPENCV_3RDPARTY_EXCLUDE_FROM_ALL} ${quirc_headers} ${quirc_sources})
  8. ocv_warnings_disable(CMAKE_C_FLAGS -Wunused-variable -Wshadow)
  9. set_target_properties(${PROJECT_NAME}
  10. PROPERTIES OUTPUT_NAME ${PROJECT_NAME}
  11. DEBUG_POSTFIX "${OPENCV_DEBUG_POSTFIX}"
  12. COMPILE_PDB_NAME ${PROJECT_NAME}
  13. COMPILE_PDB_NAME_DEBUG "${PROJECT_NAME}${OPENCV_DEBUG_POSTFIX}"
  14. ARCHIVE_OUTPUT_DIRECTORY ${3P_LIBRARY_OUTPUT_PATH}
  15. )
  16. if(ENABLE_SOLUTION_FOLDERS)
  17. set_target_properties(${PROJECT_NAME} PROPERTIES FOLDER "3rdparty")
  18. endif()
  19. if(NOT BUILD_SHARED_LIBS)
  20. ocv_install_target(${PROJECT_NAME} EXPORT OpenCVModules ARCHIVE DESTINATION ${OPENCV_3P_LIB_INSTALL_PATH} COMPONENT dev OPTIONAL)
  21. endif()
  22. ocv_install_3rdparty_licenses(${PROJECT_NAME} LICENSE)