PCL currently provides imported targets without namespacing (e.g., pcl_common, pcl_io, pcl_visualization), rather than using PackageName::Component naming conventions (e.g., PCL::common, PCL::io, PCL::visualization), which is commonly seen in many packages (Eigen3, Boost, VTK...)
If so, we can write:
find_package(PCL REQUIRED COMPONENTS io common)
target_link_libraries(foo PCL::io PCL::common)
or we can even have a target PCL::PCL to include all imported targets.
PCL currently provides imported targets without namespacing (e.g.,
pcl_common,pcl_io,pcl_visualization), rather than usingPackageName::Componentnaming conventions (e.g.,PCL::common,PCL::io,PCL::visualization), which is commonly seen in many packages (Eigen3, Boost, VTK...)If so, we can write:
or we can even have a target
PCL::PCLto include all imported targets.