11cmake_minimum_required (VERSION 3.5)
2- include_directories ( "${CMAKE_CURRENT_SOURCE_DIR} " )
2+ include_directories ("${CMAKE_CURRENT_SOURCE_DIR} " )
33
4- add_library ( ${RAWTOACESIDTLIB} ${DO_SHARED}
4+ add_library (${RAWTOACESIDTLIB} ${DO_SHARED}
55 rta.cpp
66 ../../include /rawtoaces/define.h
77 ../../include /rawtoaces/mathOps.h
@@ -14,45 +14,45 @@ target_include_directories(${RAWTOACESIDTLIB}
1414 $<INSTALL_INTERFACE:include >
1515)
1616
17- target_link_libraries (
18- ${RAWTOACESIDTLIB}
17+ target_link_libraries (${RAWTOACESIDTLIB}
1918 PUBLIC
20- Eigen3::Eigen
19+ Eigen3::Eigen
2120)
2221
2322target_link_libraries (${RAWTOACESIDTLIB}
2423 PRIVATE
25- Eigen3::Eigen
2624 Boost::filesystem
2725 Boost::system
26+ Imath::Imath
27+ Imath::ImathConfig
2828)
2929
30- if (TARGET libraw::raw )
31- target_link_libraries (${RAWTOACESIDTLIB} PUBLIC libraw::raw )
30+ if (TARGET LibRaw::LibRaw )
31+ target_link_libraries (${RAWTOACESIDTLIB} PUBLIC LibRaw::LibRaw )
3232else ()
33- if (libraw_INCLUDE_DIRS)
34- target_include_directories (${RAWTOACESIDTLIB} PUBLIC ${LibRaw_INCLUDE_DIRS} )
33+ if (LibRaw_INCLUDE_DIRS)
34+ target_include_directories (${RAWTOACESIDTLIB}
35+ PUBLIC $<BUILD_INTERFACE:${LibRaw_INCLUDE_DIRS} >
36+ )
3537 endif ()
36- if (libraw_LIBRARY_DIRS )
38+ if (LibRaw_LIBRARY_DIRS )
3739 target_link_directories (${RAWTOACESIDTLIB} PRIVATE ${LibRaw_LIBRARY_DIRS} )
3840 endif ()
39- if (libraw_LIBRARIES )
41+ if (LibRaw_LIBRARIES )
4042 target_link_libraries (${RAWTOACESIDTLIB} PUBLIC ${LibRaw_LIBRARIES} ${LibRaw_LDFLAGS_OTHER} )
4143 endif ()
4244endif ()
4345
44- target_link_libraries (${RAWTOACESIDTLIB}
45- PRIVATE
46- Imath::Imath
47- Imath::ImathConfig
48- )
49-
50- if ( ${Ceres_VERSION_MAJOR} GREATER 1 )
51- target_link_libraries ( ${RAWTOACESIDTLIB} PUBLIC Ceres::ceres )
52- else ()
53- target_include_directories (${RAWTOACESIDTLIB} PUBLIC ${CERES_INCLUDE_DIRS} )
46+ if (${Ceres_VERSION_MAJOR} GREATER 1)
47+ target_link_libraries (${RAWTOACESIDTLIB} PUBLIC Ceres::ceres)
48+ else ()
49+ if (CERES_INCLUDE_DIRS)
50+ target_include_directories (${RAWTOACESIDTLIB}
51+ PUBLIC $<BUILD_INTERFACE:${CERES_INCLUDE_DIRS} >
52+ )
53+ endif ()
5454 target_link_libraries (${RAWTOACESIDTLIB} PUBLIC ${CERES_LIBRARIES} )
55- endif ()
55+ endif ()
5656
5757set (RAWTOACESIDT_HEADERS
5858 ${PROJECT_SOURCE_DIR} /include /rawtoaces/define.h
0 commit comments