Skip to content

Commit

Permalink
Do not link against PYTHON_LIBRARIES on macOS
Browse files Browse the repository at this point in the history
Signed-off-by: Tobias-Fischer <[email protected]>
  • Loading branch information
Tobias-Fischer committed Mar 3, 2022
1 parent 17de859 commit 419fc2a
Showing 1 changed file with 11 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -169,10 +169,17 @@ add_dependencies(
${rosidl_generate_interfaces_TARGET}__rosidl_typesupport_c
)

target_link_libraries(
${_target_name_lib}
${PythonExtra_LIBRARIES}
)

if(NOT APPLE)
target_link_libraries(
${_target_name_lib}
${PythonExtra_LIBRARIES}
)
else()
set_target_properties(${_target_name_lib} PROPERTIES
LINK_FLAGS "-undefined dynamic_lookup")
endif()

target_include_directories(${_target_name_lib}
PUBLIC
${CMAKE_CURRENT_BINARY_DIR}/rosidl_generator_c
Expand Down

0 comments on commit 419fc2a

Please sign in to comment.