Skip to content

[cmake] Provide namespaced alias targets (PCL::<component>) in PCLConfig.cmake (#6397) - #6463

Open
kai-waang wants to merge 1 commit into
PointCloudLibrary:masterfrom
kai-waang:cmake-namespace-alias-targets
Open

[cmake] Provide namespaced alias targets (PCL::<component>) in PCLConfig.cmake (#6397)#6463
kai-waang wants to merge 1 commit into
PointCloudLibrary:masterfrom
kai-waang:cmake-namespace-alias-targets

Conversation

@kai-waang

Copy link
Copy Markdown
Contributor

As discussed in #6397, Downstream projects can now link e.g. PCL::common or PCL::geometry. An ALIAS of a non-global imported target requires CMake >= 3.18, so emulate it with an INTERFACE IMPORTED wrapper for older versions.

Downstream projects can now link e.g. PCL::common or PCL::geometry.
An ALIAS of a non-global imported target requires CMake >= 3.18, so
emulate it with an INTERFACE IMPORTED wrapper for older versions.

Fixes PointCloudLibrary#6397
@mvieth mvieth added changelog: enhancement Meta-information for changelog generation module: cmake labels Aug 16, 2026
@mvieth

mvieth commented Aug 16, 2026

Copy link
Copy Markdown
Member

Great, thanks! What do you think about also adding the following somewhere here:

add_library(PCL::PCL INTERFACE IMPORTED)
target_link_libraries(PCL::PCL INTERFACE ${PCL_COMPONENTS})

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog: enhancement Meta-information for changelog generation module: cmake

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants