Skip to content
Snippets Groups Projects

Help: Modernize PackageConfigHelpers example

Merged Frank Dana requested to merge ferdnyc/cmake:gen-pkg-example into master

The example shown in the module documentation for CMakePackageConfigHelpers was showing its age, by:

  1. Hardcoding directory prefixes (etc/, lib/, etc.) instead of using GNUInstallDirs
  2. Handwaving set() commands (incorrectly!) as:
    set(VAR dir/ ... CACHE )
    which should, at the very least, be:
    set(VAR dir/ CACHE ... )
  3. Installing CMake configuration files to lib/Foo/cmake/, when current practice favors ${CMAKE_INSTALL_LIBDIR}/cmake/Foo/

This updated example addresses all of those issues.

Edited by Frank Dana

Merge request reports

Merge request pipeline #315530 waiting for manual action

Merge request pipeline waiting for manual action for bfa61ccf

Approval is optional

Merged by Kitware RobotKitware Robot 2 years ago (Jan 24, 2023 2:20pm UTC)

Merge details

  • Changes merged into master with 62483b9b.
  • Deleted the source branch.

Pipeline #315768 failed

Pipeline failed for 62483b9b on master

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
Please register or sign in to reply
Loading