Skip to content

Commit

Permalink
build: link reapi golang bindings with planner
Browse files Browse the repository at this point in the history
Problem: Now that libresource is no longer marked SHARED, it seems
that the reapi Go bindings need to explicitly include libplanner
and libplanner_cxx.

Add the explicit linkage to planner in CGO_LIBRARY_FLAGS.
  • Loading branch information
grondo committed Oct 2, 2023
1 parent 79ec8fc commit bddcfbb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion resource/reapi/bindings/go/src/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ set(SRCS main.go)
set(CGO_CFLAGS "-I${CMAKE_BINARY_DIR}/resource/reapi/bindings/c")

# This is currently passed but not used because when passed into add_custom_command the spaces are escaped
set(CGO_LIBRARY_FLAGS "-Wl,-R ${CMAKE_BINARY_DIR}/resource -L${CMAKE_BINARY_DIR}/resource/reapi/bindings -L${CMAKE_BINARY_DIR}/resource/libjobspec -ljobspec_conv -lreapi_cli -L${CMAKE_BINARY_DIR}/resource -lresource -lflux-idset -lstdc++ -lczmq -ljansson -lhwloc -lboost_system -lflux-hostlist -lboost_graph -lyaml-cpp")
set(CGO_LIBRARY_FLAGS "-Wl,-R ${CMAKE_BINARY_DIR}/resource -L${CMAKE_BINARY_DIR}/resource/reapi/bindings -L${CMAKE_BINARY_DIR}/resource/libjobspec -ljobspec_conv -lreapi_cli -L${CMAKE_BINARY_DIR}/resource -lresource -L${CMAKE_BINARY_DIR}/resource/planner/c -lplanner -L${CMAKE_BINARY_DIR}/resource/planner/c++ -lplanner_cxx -lflux-idset -lstdc++ -lczmq -ljansson -lhwloc -lboost_system -lflux-hostlist -lboost_graph -lyaml-cpp")

# This ensures the main binary is cleaned up
set_directory_properties(
Expand Down

0 comments on commit bddcfbb

Please sign in to comment.