Skip to content

CMake change #53

@nicolastd

Description

@nicolastd

When trying to compile GKlib, I would like to specify the installation lib. This is a standard CMake mechanism, but it is not working at the moment. However, the simple patch bellow allow to use make config ... CONFIG_FLAGS="-DCMAKE_INSTALL_LIBDIR=$HOME/ParMETIS/lib" properly.

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6a9a694..e13b403 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -221,11 +221,11 @@ install(DIRECTORY "${CMAKE_SOURCE_DIR}/include/"
 install(EXPORT GKlibTargets
   FILE        GKlibTargets.cmake
   NAMESPACE   GKlib::
-  DESTINATION lib/cmake/GKlib
+  DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/GKlib
   COMPONENT   GKlib_Development)
 
 install(
   FILES       ${CMAKE_CURRENT_BINARY_DIR}/cmake/GKlibConfig.cmake
               ${CMAKE_CURRENT_BINARY_DIR}/cmake/GKlibConfigVersion.cmake
-  DESTINATION lib/cmake/GKlib
+  DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/GKlib
   COMPONENT   GKlib_Development)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions