diff --git a/Code/Common/CMakeLists.txt b/Code/Common/CMakeLists.txt index c6f7d53028f19c5f6159a2602b621b6ceb7f2560..5196576f0157f05b28f1af7eb8b7cbe8dda185fa 100644 --- a/Code/Common/CMakeLists.txt +++ b/Code/Common/CMakeLists.txt @@ -12,6 +12,10 @@ ENDIF( NOT OTB_USE_PQXX ) ADD_LIBRARY(OTBCommon ${OTBCommon_SRCS}) +SET_TARGET_PROPERTIES(OTBCommon + PROPERTIES + LINK_INTERFACE_LIBRARIES "" +) TARGET_LINK_LIBRARIES (OTBCommon ITKAlgorithms ITKStatistics ITKCommon otbconfigfile) IF(OTB_USE_MAPNIK) TARGET_LINK_LIBRARIES(OTBCommon ${MAPNIK_LIBRARY}) diff --git a/Code/IO/CMakeLists.txt b/Code/IO/CMakeLists.txt index db0c68c9f84515f0dbcd5308475d29b5e15c34d8..3d1f1208ee5452970df8897c7d2850781c21a0ae 100644 --- a/Code/IO/CMakeLists.txt +++ b/Code/IO/CMakeLists.txt @@ -30,7 +30,11 @@ ENDIF(OTB_COMPILE_JPEG2000) ADD_LIBRARY(OTBIO ${OTBIO_SRCS}) -TARGET_LINK_LIBRARIES (OTBIO ${GDAL_LIBRARY} ${OGR_LIBRARY} ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} ${JPEG_LIBRARY} OTBCommon) + SET_TARGET_PROPERTIES(OTBIO + PROPERTIES + LINK_INTERFACE_LIBRARIES "" + ) +TARGET_LINK_LIBRARIES (OTBIO ${GDAL_LIBRARY} ${OGR_LIBRARY} ${JPEG_LIBRARY} ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} OTBCommon) TARGET_LINK_LIBRARIES (OTBIO otbossim otbossimplugins ITKIO ITKCommon dxf otbkml) IF (OTB_USE_LIBLAS) diff --git a/Code/Testing/CMakeLists.txt b/Code/Testing/CMakeLists.txt index 091ed1945f72a6ec4c9334265e5bc550784887e2..29bf017a0ae02846dd94de4793e18e0e95ae4c6e 100644 --- a/Code/Testing/CMakeLists.txt +++ b/Code/Testing/CMakeLists.txt @@ -3,6 +3,10 @@ FILE(GLOB OTBTesting_SRCS "*.cxx" ) ADD_LIBRARY(OTBTesting ${OTBTesting_SRCS}) +SET_TARGET_PROPERTIES(OTBTesting + PROPERTIES + LINK_INTERFACE_LIBRARIES "" +) TARGET_LINK_LIBRARIES (OTBTesting OTBBasicFilters OTBIO OTBCommon ITKBasicFilters) IF(OTB_LIBRARY_PROPERTIES) SET_TARGET_PROPERTIES(OTBTesting PROPERTIES ${OTB_LIBRARY_PROPERTIES}) diff --git a/Utilities/otbossim/CMakeLists.txt b/Utilities/otbossim/CMakeLists.txt index b4dd3dbd94c4bceb8f44ae6f1de9b968b86c195a..e6b2ca5c74ead4ed1d7423815901d7cbe35ff838 100644 --- a/Utilities/otbossim/CMakeLists.txt +++ b/Utilities/otbossim/CMakeLists.txt @@ -139,10 +139,15 @@ IF(NOT OTB_DISABLE_UTILITIES_COMPILATION) ${ossim_projection_SRCS} ${ossim_imaging_SRCS} ${ossim_parallel_SRCS} - ${ossim_elevation_SRCS} + ${ossim_elevation_SRCS}) + SET_TARGET_PROPERTIES(otbossim + PROPERTIES + LINK_INTERFACE_LIBRARIES "" + ) # TARGET_LINK_LIBRARIES(otbossim ${GDAL_LIBRARY})#To make sure that gdal appear before geotiff -# TARGET_LINK_LIBRARIES(otbossim ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} ${JPEG_LIBRARY} ${OPENTHREADS_LIBRARY}) +# TARGET_LINK_LIBRARIES(otbossim ${JPEG_LIBRARY} ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} ${OPENTHREADS_LIBRARY}) + TARGET_LINK_LIBRARIES(otbossim ${OPENTHREADS_LIBRARY}) IF(NOT OTB_INSTALL_NO_LIBRARIES) INSTALL(TARGETS otbossim