Skip to content

Commit

Permalink
Fix set_property for proto targets.
Browse files Browse the repository at this point in the history
Signed-off-by: owent <admin@owent.net>
  • Loading branch information
owent committed Apr 20, 2023
1 parent 643fdfb commit 69860c8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions cmake/opentelemetry-proto.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -299,13 +299,14 @@ if(WITH_OTLP_GRPC)
if(WITH_ABSEIL)
find_package(absl CONFIG)
if(TARGET absl::synchronization)
target_link_libraries(opentelemetry_proto_grpc PRIVATE absl::synchronization)
target_link_libraries(opentelemetry_proto_grpc
PRIVATE absl::synchronization)
endif()
endif()
endif()

if(BUILD_SHARED_LIBS)
foreach(proto_target ${OPENTELEMETRY_PROTO_TARGETS})
set_property(TARGET proto_target PROPERTY POSITION_INDEPENDENT_CODE ON)
set_property(TARGET ${proto_target} PROPERTY POSITION_INDEPENDENT_CODE ON)
endforeach()
endif()

0 comments on commit 69860c8

Please sign in to comment.