From: Andrey Kamaev Date: Sun, 11 Mar 2012 15:22:38 +0000 (+0000) Subject: Fixed broken headers install layout X-Git-Tag: accepted/tizen/6.0/unified/20201030.111113~5390 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=628076b7da02720752fb90d41563267d1257e838;p=platform%2Fupstream%2Fopencv.git Fixed broken headers install layout --- diff --git a/cmake/OpenCVModule.cmake b/cmake/OpenCVModule.cmake index f9ce195..699808c 100644 --- a/cmake/OpenCVModule.cmake +++ b/cmake/OpenCVModule.cmake @@ -426,8 +426,11 @@ macro(ocv_create_module) # only "public" headers need to be installed if(OPENCV_MODULE_${the_module}_HEADERS AND OPENCV_MODULES_PUBLIC MATCHES "(^|;)${the_module}(;|$)") - install(FILES ${OPENCV_MODULE_${the_module}_HEADERS} - DESTINATION ${OPENCV_INCLUDE_PREFIX}/opencv2/${name} COMPONENT main) + foreach(hdr ${OPENCV_MODULE_${the_module}_HEADERS}) + if(hdr MATCHES "(opencv2/.*)/[^/]+.h(..)?$") + install(FILES ${hdr} DESTINATION "${OPENCV_INCLUDE_PREFIX}/${CMAKE_MATCH_1}" COMPONENT main) + endif() + endforeach() endif() endmacro()