vcpkg/ports/pcl/fix-link-libpng.patch

21 lines
872 B
Diff
Raw Normal View History

diff --git a/io/CMakeLists.txt b/io/CMakeLists.txt
2020-08-19 06:20:22 +08:00
index f234971..86ea242 100644
--- a/io/CMakeLists.txt
+++ b/io/CMakeLists.txt
2020-08-19 06:20:22 +08:00
@@ -333,12 +333,13 @@ set(LIB_NAME "pcl_${SUBSYS_NAME}")
add_definitions(${VTK_DEFINES})
PCL_ADD_LIBRARY(${LIB_NAME} COMPONENT ${SUBSYS_NAME} SOURCES ${srcs} ${incs} ${compression_incs} ${impl_incs} ${OPENNI_INCLUDES} ${OPENNI2_INCLUDES})
target_include_directories(${LIB_NAME} PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include")
-link_directories(${VTK_LINK_DIRECTORIES})
-target_link_libraries("${LIB_NAME}" pcl_common pcl_io_ply ${VTK_LIBRARIES})
if(PNG_FOUND)
target_link_libraries("${LIB_NAME}" ${PNG_LIBRARIES})
endif()
2020-08-19 06:20:22 +08:00
+link_directories(${VTK_LINK_DIRECTORIES})
+target_link_libraries("${LIB_NAME}" pcl_common pcl_io_ply ${VTK_LIBRARIES})
+
if(LIBUSB_1_FOUND)
target_link_libraries("${LIB_NAME}" ${LIBUSB_1_LIBRARIES})
endif()