Skip to content

Commit ee11896

Browse files
authored
Fix make vineyard_client_python on macos. (#1989)
When running `make vineyard_client_python` on macos, get the following error: ``` ld: unknown option: --version-script= clang: error: linker command failed with exit code 1 (use -v to see invocation) ``` Signed-off-by: Ye Cao <[email protected]>
1 parent cffa4d2 commit ee11896

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

CMakeLists.txt

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1011,7 +1011,9 @@ if(BUILD_VINEYARD_PYTHON_BINDINGS)
10111011
DEPENDS _C vineyard_internal_registry
10121012
COMMENT "Copying python extensions."
10131013
VERBATIM)
1014-
set_target_properties(_C PROPERTIES LINK_FLAGS "-Wl,--version-script=${LIBFABRIC_VERSION_SCRIPT}")
1014+
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
1015+
set_target_properties(_C PROPERTIES LINK_FLAGS "-Wl,--version-script=${LIBFABRIC_VERSION_SCRIPT}")
1016+
endif()
10151017
endif()
10161018

10171019
if(BUILD_VINEYARD_PYTHON_BINDINGS AND BUILD_VINEYARD_LLM_CACHE)
@@ -1027,7 +1029,9 @@ if(BUILD_VINEYARD_PYTHON_BINDINGS AND BUILD_VINEYARD_LLM_CACHE)
10271029
DEPENDS _llm_C
10281030
COMMENT "Copying llm kv cache python extensions."
10291031
VERBATIM)
1030-
set_target_properties(_llm_C PROPERTIES LINK_FLAGS "-Wl,--version-script=${LIBFABRIC_VERSION_SCRIPT}")
1032+
if (${CMAKE_SYSTEM_NAME} STREQUAL "Linux")
1033+
set_target_properties(_llm_C PROPERTIES LINK_FLAGS "-Wl,--version-script=${LIBFABRIC_VERSION_SCRIPT}")
1034+
endif()
10311035
add_dependencies(vineyard_llm_python vineyard_client_python)
10321036
endif()
10331037

0 commit comments

Comments
 (0)