@@ -131,6 +131,7 @@ set(BUILD_SHARED_LIBS OFF CACHE BOOL "" FORCE)
131131# Disable installs/exports in subprojects (avoids export-set errors)
132132set (protobuf_INSTALL OFF CACHE BOOL "" FORCE )
133133set (ABSL_ENABLE_INSTALL OFF CACHE BOOL "" FORCE )
134+ set (ABSL_PROPAGATE_CXX_STD ON CACHE BOOL "" FORCE )
134135set (utf8_range_ENABLE_INSTALL OFF CACHE BOOL "" FORCE )
135136
136137# Force hidden visibility on every target created by the FetchContent
@@ -159,10 +160,10 @@ if(MSVC)
159160endif ()
160161
161162# Make abseil available first so protobuf can find absl:: targets.
162- FetchContent_MakeAvailable (livekit_abseil)
163+ livekit_fetchcontent_makeavailable (livekit_abseil )
163164livekit_collect_targets_in_directory (_livekit_abseil_targets "${livekit_abseil_BINARY_DIR} " )
164165foreach (_livekit_abseil_target IN LISTS _livekit_abseil_targets)
165- livekit_treat_as_external (${_livekit_abseil_target} )
166+ livekit_disable_warnings (${_livekit_abseil_target} )
166167endforeach ()
167168
168169# Workaround for some abseil flags on Apple Silicon.
@@ -190,10 +191,10 @@ if(NOT TARGET absl::base)
190191endif ()
191192
192193# Now make protobuf available.
193- FetchContent_MakeAvailable (livekit_protobuf)
194+ livekit_fetchcontent_makeavailable (livekit_protobuf )
194195livekit_collect_targets_in_directory (_livekit_protobuf_targets "${livekit_protobuf_BINARY_DIR} " )
195196foreach (_livekit_protobuf_target IN LISTS _livekit_protobuf_targets)
196- livekit_treat_as_external (${_livekit_protobuf_target} )
197+ livekit_disable_warnings (${_livekit_protobuf_target} )
197198endforeach ()
198199
199200# Protobuf targets: modern protobuf exports protobuf::protoc etc.
@@ -216,8 +217,7 @@ endif()
216217
217218# Include dirs: prefer target usage; keep this var for your existing CMakeLists.
218219if (TARGET protobuf::libprotobuf)
219- livekit_treat_as_external (protobuf::libprotobuf )
220- get_target_property (_pb_includes protobuf::libprotobuf INTERFACE_INCLUDE_DIRECTORIES )
220+ livekit_get_interface_includes (protobuf::libprotobuf _pb_includes )
221221endif ()
222222if (NOT _pb_includes)
223223 set (_pb_includes "${livekit_protobuf_SOURCE_DIR} /src" )
0 commit comments