From: trixirt Date: Mon, 22 Jan 2024 13:02:35 +0000 (-0800) Subject: cmake : make libwhisper.so position independent (#1792) X-Git-Tag: upstream/1.7.4~1090 X-Git-Url: https://git.djapps.eu/?a=commitdiff_plain;h=1cf679dec4eca99aeaed4fe09a8092803bdecfc1;p=pkg%2Fggml%2Fsources%2Fwhisper.cpp cmake : make libwhisper.so position independent (#1792) This is similar to how libllama.so is built. Signed-off-by: Tom Rix --- diff --git a/CMakeLists.txt b/CMakeLists.txt index bab6e7ec..4c620f51 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -505,6 +505,7 @@ else() endif() if (BUILD_SHARED_LIBS) + set_target_properties(${TARGET} PROPERTIES POSITION_INDEPENDENT_CODE ON) target_link_libraries(${TARGET} PUBLIC ${CMAKE_DL_LIBS} )