Skip to content

Commit 130508f

Browse files
authored
Modernize cmake config template (#6235)
* Modernize cmake config template The helper strings was not updated for 14 year and the mentioned Targets do not seem to exist. Update to use modern style. * cmake: Update PCLConfig.cmake.in according to PR discussion
1 parent 9079226 commit 130508f

1 file changed

Lines changed: 16 additions & 2 deletions

File tree

PCLConfig.cmake.in

Lines changed: 16 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,31 @@
11
# ------------------------------------------------------------------------------------
22
# Helper to use PCL from outside project
33
#
4-
# target_link_libraries(my_fabulous_target PCL_XXX_LIBRARIES) where XXX is the
5-
# upper cased xxx from :
4+
# Search for PCL:
5+
# Request all PCL modules:
6+
# find_package(PCL CONFIG REQUIRED)
7+
# Or request only specific PCL modules:
8+
# find_package(PCL CONFIG REQUIRED COMPONENTS xxx yyy)
9+
#
10+
# Link to PCL:
11+
# Link to all found PCL modules:
12+
# target_link_libraries(my_fabulous_target ${PCL_LIBRARIES})
13+
# Or link only to specific modules:
14+
# target_link_libraries(my_fabulous_target pcl_xxx pcl_yyy)
15+
#
16+
# Where xxx and yyy are module names from the following list:
617
# @PCLCONFIG_AVAILABLE_COMPONENTS_LIST@
718
#
19+
# Some additional variables are set by PCLConfig.cmake, which are not needed when
20+
# using the (modern) linking approach described above:
821
# PCL_INCLUDE_DIRS is filled with PCL and available 3rdparty headers
922
# PCL_LIBRARY_DIRS is filled with PCL components libraries install directory and
1023
# 3rdparty libraries paths
1124
#
1225
# www.pointclouds.org
1326
#------------------------------------------------------------------------------------
1427

28+
1529
# Set default policy behavior similar to minimum requirement version
1630
cmake_policy(VERSION 3.16.3)
1731

0 commit comments

Comments
 (0)