fix(build): relocate cmake and pkgconfig files to an arch-independent path (#635)

* Relocate cmake and pkgconfig files to an arch-independent path

Use CMAKE_INSTALL_DATADIR instead of CMAKE_INSTALL_LIBDIR for
installing the pkgconfig and cmake files.

Signed-off-by: Jose Luis Rivero <jrivero@osrfoundation.org>

* style: pre-commit.ci fixes

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Jose Luis Rivero
2021-08-23 05:51:30 +02:00
committed by GitHub
parent 2d2372d596
commit d17016e76c
2 changed files with 3 additions and 3 deletions

View File

@@ -197,14 +197,14 @@ if(CLI11_INSTALL)
# Make version available in the install
install(FILES "${PROJECT_BINARY_DIR}/CLI11ConfigVersion.cmake"
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/CLI11")
DESTINATION "${CMAKE_INSTALL_DATADIR}/cmake/CLI11")
# Install the export target as a file
install(
EXPORT CLI11Targets
FILE CLI11Config.cmake
NAMESPACE CLI11::
DESTINATION "${CMAKE_INSTALL_LIBDIR}/cmake/CLI11")
DESTINATION "${CMAKE_INSTALL_DATADIR}/cmake/CLI11")
# Use find_package on the installed package
export(