From 25f22aee8285e1e7fb0a1dabaffa5efcc90b1186 Mon Sep 17 00:00:00 2001 From: miriameng Date: Sun, 5 Mar 2023 19:23:57 -0800 Subject: [PATCH 1/2] merge pcl_io_ply into pcl_io to resolve #4422 --- io/CMakeLists.txt | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/io/CMakeLists.txt b/io/CMakeLists.txt index dcba298032d..c67704f12d2 100644 --- a/io/CMakeLists.txt +++ b/io/CMakeLists.txt @@ -204,15 +204,6 @@ set(PLY_INCLUDES "include/pcl/${SUBSYS_NAME}/ply/ply_parser.h" ) -PCL_ADD_LIBRARY(pcl_io_ply COMPONENT ${SUBSYS_NAME} SOURCES ${PLY_SOURCES} ${PLY_INCLUDES}) -if(MINGW) - # libws2_32 isn't added by default for MinGW - target_link_libraries(pcl_io_ply ws2_32) -endif() -PCL_ADD_INCLUDES("${SUBSYS_NAME}" "${SUBSYS_NAME}/ply" ${PLY_INCLUDES}) -target_include_directories(pcl_io_ply PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include") -target_link_libraries(pcl_io_ply pcl_common Boost::boost) - set(srcs src/debayer.cpp src/pcd_grabber.cpp @@ -339,11 +330,11 @@ 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}) +PCL_ADD_LIBRARY(${LIB_NAME} COMPONENT ${SUBSYS_NAME} SOURCES ${srcs} ${incs} ${compression_incs} ${impl_incs} ${OPENNI_INCLUDES} ${OPENNI2_INCLUDES} ${PLY_SOURCES} ${PLY_INCLUDES}) target_include_directories(${LIB_NAME} PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}/include") -target_link_libraries("${LIB_NAME}" Boost::boost Boost::filesystem Boost::iostreams pcl_common pcl_io_ply) +target_link_libraries("${LIB_NAME}" Boost::boost Boost::filesystem Boost::iostreams pcl_common) if(VTK_FOUND) if(${VTK_VERSION} VERSION_GREATER_EQUAL 9.0) From a9543ac17a89aa68f8965a85b583c181596d8273 Mon Sep 17 00:00:00 2001 From: miriameng Date: Sat, 11 Mar 2023 21:43:03 -0800 Subject: [PATCH 2/2] put PLY_SOURCES and PLY_INCLUDES in srcs and incs --- io/CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/io/CMakeLists.txt b/io/CMakeLists.txt index c67704f12d2..f3410f8aacf 100644 --- a/io/CMakeLists.txt +++ b/io/CMakeLists.txt @@ -233,6 +233,7 @@ set(srcs ${DSSDK_GRABBER_SOURCES} ${RSSDK_GRABBER_SOURCES} ${RSSDK2_GRABBER_SOURCES} + ${PLY_SOURCES} ) if(PNG_FOUND) @@ -286,6 +287,7 @@ set(incs ${DSSDK_GRABBER_INCLUDES} ${RSSDK_GRABBER_INCLUDES} ${RSSDK2_GRABBER_INCLUDES} + ${PLY_INCLUDES} ) set(compression_incs @@ -330,7 +332,7 @@ 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} ${PLY_SOURCES} ${PLY_INCLUDES}) +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")