Skip to content

Commit

Permalink
cmake : make libwhisper.so position independent (openai#1792)
Browse files Browse the repository at this point in the history
This is similar to how libllama.so is built.

Signed-off-by: Tom Rix <[email protected]>
  • Loading branch information
trixirt authored Jan 22, 2024
1 parent 41026c1 commit 1cf679d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -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}
)
Expand Down

0 comments on commit 1cf679d

Please sign in to comment.