You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With the latest merge of #2100, there is a problem when a library is linking to another library that links to PCL, please see below minimal to reproduce the problem.
-- Eigen found (include: /usr/include/eigen3, version: 3.3.90)
-- Boost version: 1.65.1
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
-- serialization
-- chrono
-- atomic
-- regex
-- FLANN found (include: /usr/include, lib: optimized;/usr/lib/libflann_cpp.so;debug;/usr/lib/libflann_cpp.so)
-- FLANN found (include: /usr/include, lib: optimized;/usr/lib/libflann_cpp.so;debug;/usr/lib/libflann_cpp.so)
** WARNING ** io features related to pcap will be disabled
** WARNING ** io features related to png will be disabled
-- LIBUSB_1_LIBRARY (missing: LIBUSB_1_INCLUDE_DIR)
** WARNING ** io features related to libusb-1.0 will be disabled
-- QHULL found (include: /usr/include, lib: optimized;/usr/lib/x86_64-linux-gnu/libqhull.so;debug;/usr/lib/x86_64-linux-gnu/libqhull.so)
-- looking for PCL_COMMON
-- looking for PCL_KDTREE
-- looking for PCL_OCTREE
-- looking for PCL_SEARCH
-- looking for PCL_SAMPLE_CONSENSUS
-- looking for PCL_FILTERS
-- looking for PCL_2D
-- looking for PCL_GEOMETRY
-- looking for PCL_IO
-- looking for PCL_FEATURES
-- looking for PCL_ML
-- looking for PCL_SEGMENTATION
-- looking for PCL_VISUALIZATION
-- looking for PCL_SURFACE
-- looking for PCL_REGISTRATION
-- looking for PCL_KEYPOINTS
-- looking for PCL_TRACKING
-- looking for PCL_RECOGNITION
-- looking for PCL_STEREO
-- looking for PCL_CUDA_COMMON
-- looking for PCL_CUDA_FEATURES
-- looking for PCL_CUDA_SEGMENTATION
-- looking for PCL_CUDA_SAMPLE_CONSENSUS
-- looking for PCL_OUTOFCORE
-- looking for PCL_GPU_CONTAINERS
-- looking for PCL_GPU_UTILS
-- looking for PCL_GPU_OCTREE
-- looking for PCL_GPU_FEATURES
-- looking for PCL_GPU_SEGMENTATION
-- looking for PCL_PEOPLE
-- Eigen found (include: /usr/include/eigen3, version: 3.3.90)
-- Boost version: 1.65.1
-- Found the following Boost libraries:
-- system
-- filesystem
-- thread
-- date_time
-- iostreams
-- serialization
-- chrono
-- atomic
-- regex
-- FLANN found (include: /usr/include, lib: optimized;/usr/lib/libflann_cpp.so;debug;/usr/lib/libflann_cpp.so)
-- FLANN found (include: /usr/include, lib: optimized;/usr/lib/libflann_cpp.so;debug;/usr/lib/libflann_cpp.so)
** WARNING ** io features related to pcap will be disabled
** WARNING ** io features related to png will be disabled
-- LIBUSB_1_LIBRARY (missing: LIBUSB_1_INCLUDE_DIR)
** WARNING ** io features related to libusb-1.0 will be disabled
-- QHULL found (include: /usr/include, lib: optimized;/usr/lib/x86_64-linux-gnu/libqhull.so;debug;/usr/lib/x86_64-linux-gnu/libqhull.so)
-- looking for PCL_COMMON
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_common" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_KDTREE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_kdtree" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_OCTREE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_octree" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_SEARCH
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_search" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_SAMPLE_CONSENSUS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_sample_consensus" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_FILTERS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_filters" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_2D
-- looking for PCL_GEOMETRY
-- looking for PCL_IO
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_io" because another target
with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_FEATURES
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_features" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_ML
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_ml" because another target
with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_SEGMENTATION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_segmentation" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_VISUALIZATION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_visualization" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_SURFACE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_surface" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_REGISTRATION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_registration" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_KEYPOINTS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_keypoints" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_TRACKING
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_tracking" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_RECOGNITION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_recognition" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_STEREO
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_stereo" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_CUDA_COMMON
-- looking for PCL_CUDA_FEATURES
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_cuda_features" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_CUDA_SEGMENTATION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_cuda_segmentation" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_CUDA_SAMPLE_CONSENSUS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_cuda_sample_consensus"
because another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_OUTOFCORE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_outofcore" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_GPU_CONTAINERS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_gpu_containers" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_GPU_UTILS
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_gpu_utils" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_GPU_OCTREE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_gpu_octree" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_GPU_FEATURES
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_gpu_features" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_GPU_SEGMENTATION
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_gpu_segmentation" because
another target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- looking for PCL_PEOPLE
CMake Error at /usr/share/pcl-1.8/PCLConfig.cmake:630 (add_library):
add_library cannot create imported target "pcl_people" because another
target with the same name already exists.
Call Stack (most recent call first):
sample2/CMakeLists.txt:5 (find_package)
-- Configuring incomplete, errors occurred!
This problem pops up only after the merge of #2100, if I remove the find_package( PCL REQUIRED ) in sample2/CMakeLists.txt the error goes away, but I should be allowed to call find_package( PCL REQUIRED ) in sample2/CMakeLists.txt even if it's redundant.
The text was updated successfully, but these errors were encountered:
Your Environment
Context
With the latest merge of #2100, there is a problem when a library is linking to another library that links to PCL, please see below minimal to reproduce the problem.
CMakeLists.txt
Sample.cpp
Sample.h
sample2/CMakeLists.txt
sample2/Sample2.cpp
sample2/Sample2.h
Expected Behavior
After
It should work without a problem.
Current Behavior
However, here is the output
This problem pops up only after the merge of #2100, if I remove the
find_package( PCL REQUIRED )
in sample2/CMakeLists.txt the error goes away, but I should be allowed to callfind_package( PCL REQUIRED )
in sample2/CMakeLists.txt even if it's redundant.The text was updated successfully, but these errors were encountered: