]> git.djapps.eu Git - pkg/ggml/sources/whisper.cpp/commitdiff
cmake : do not assume /usr/lib library installation. (#3693)
authorPatrice Levesque <redacted>
Tue, 2 Jun 2026 07:22:16 +0000 (03:22 -0400)
committerGitHub <redacted>
Tue, 2 Jun 2026 07:22:16 +0000 (09:22 +0200)
Current `pkgconfig` configuration file installation path and its
contents assume libraries are installed under `/usr/lib` and this is not
always the case, for instance `/usr/lib64` is quite possible under
Gentoo Linux.

Thus use the `CMAKE_INSTALL_LIBDIR` variable instead of a hardcoded
`lib`.

CMakeLists.txt
cmake/whisper.pc.in

index 4df278c3ad838485e2275e5e65cfc9aa361b85d3..3932cf2845e5452bb3fe3fe9d67b1bb1cf75636a 100644 (file)
@@ -209,7 +209,7 @@ configure_file(cmake/whisper.pc.in
         @ONLY)
 
 install(FILES "${CMAKE_CURRENT_BINARY_DIR}/whisper.pc"
-        DESTINATION lib/pkgconfig)
+        DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig)
 
 #
 # programs, examples and tests
index 00ec7912014c02defe39add37a4b92adc3ea0afa..200179d5d11a75bfaf19d99e721c09518362b8b7 100644 (file)
@@ -1,6 +1,6 @@
 prefix=@CMAKE_INSTALL_PREFIX@
 exec_prefix=${prefix}
-libdir=${exec_prefix}/lib
+libdir=${prefix}/@CMAKE_INSTALL_LIBDIR@
 includedir=${prefix}/include
 
 Name: whisper