mbonadei d00aad5eb2 Revert of Loosening the coupling between WebRTC and //third_party/protobuf (patchset #16 id:300001 of https://codereview.webrtc.org/2747863003/ )
Reason for revert:
I will try to reland next week because it is causing some problems.

Original issue's description:
> To accommodate some downstream WebRTC users we need to loosen
> the coupling between our code and the //third_party/protobuf.
>
> This includes using typedefs to define strings instead of
> assuming std::string.
>
> After this refactoring it will be possible to link with other
> protobuf implementations than the current one.
>
> We moved the PRESUBMIT check to another CL [1]. The goal of this
> presubmit is to avoid the direct usage of google::protobuf outside
> of the webrtc/base/protobuf_utils.h header file.
>
> [1] - https://codereview.webrtc.org/2753823003/
>
> BUG=webrtc:7340
> NOTRY=True
>
> Review-Url: https://codereview.webrtc.org/2747863003
> Cr-Commit-Position: refs/heads/master@{#17466}
> Committed: 16ab93b952

TBR=kjellander@webrtc.org,henrik.lundin@webrtc.org,kwiberg@webrtc.org,michaelt@webrtc.org,peah@webrtc.org
# Not skipping CQ checks because original CL landed more than 1 days ago.
BUG=webrtc:7340

Review-Url: https://codereview.webrtc.org/2786363002
Cr-Commit-Position: refs/heads/master@{#17483}
2017-03-31 10:08:07 +00:00

176 lines
5.0 KiB
Plaintext

# Copyright (c) 2016 The WebRTC project authors. All Rights Reserved.
#
# Use of this source code is governed by a BSD-style license
# that can be found in the LICENSE file in the root of the source
# tree. An additional intellectual property rights grant can be found
# in the file PATENTS. All contributing project authors may
# be found in the AUTHORS file in the root of the source tree.
import("../webrtc.gni")
import("//third_party/protobuf/proto_library.gni")
if (is_android) {
import("//build/config/android/config.gni")
import("//build/config/android/rules.gni")
}
group("logging") {
public_deps = [
":rtc_event_log_impl",
]
if (rtc_enable_protobuf) {
public_deps += [ ":rtc_event_log_parser" ]
}
}
rtc_source_set("rtc_event_log_api") {
# TODO(kjellander): Remove (bugs.webrtc.org/7257)
# Enabling GN check triggers cyclic dependency error:
# //webrtc/logging:rtc_event_log_api ->
# //webrtc/modules/audio_coding:audio_network_adaptor ->
# //webrtc/logging:rtc_event_log_api
check_includes = false
sources = [
"rtc_event_log/rtc_event_log.h",
]
deps = [
"../base:rtc_base_approved",
"../call:call_interfaces",
]
}
rtc_static_library("rtc_event_log_impl") {
sources = [
"rtc_event_log/ringbuffer.h",
"rtc_event_log/rtc_event_log.cc",
"rtc_event_log/rtc_event_log_helper_thread.cc",
"rtc_event_log/rtc_event_log_helper_thread.h",
]
defines = []
deps = [
":rtc_event_log_api",
"..:webrtc_common",
"../base:rtc_base_approved",
"../call:call_interfaces",
"../modules/audio_coding:audio_network_adaptor",
"../modules/rtp_rtcp",
"../system_wrappers",
]
if (rtc_enable_protobuf) {
defines += [ "ENABLE_RTC_EVENT_LOG" ]
deps += [ ":rtc_event_log_proto" ]
}
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
if (rtc_enable_protobuf) {
proto_library("rtc_event_log_proto") {
sources = [
"rtc_event_log/rtc_event_log.proto",
]
proto_out_dir = "webrtc/logging/rtc_event_log"
}
rtc_static_library("rtc_event_log_parser") {
sources = [
"rtc_event_log/rtc_event_log_parser.cc",
"rtc_event_log/rtc_event_log_parser.h",
]
public_deps = [
":rtc_event_log_api",
":rtc_event_log_proto",
"..:webrtc_common",
"../call:call_interfaces",
"../modules/rtp_rtcp:rtp_rtcp",
"../system_wrappers",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
deps = [
"../base:rtc_base_approved",
]
}
if (rtc_include_tests) {
rtc_source_set("rtc_event_log_tests") {
testonly = true
sources = [
"rtc_event_log/ringbuffer_unittest.cc",
"rtc_event_log/rtc_event_log_unittest.cc",
"rtc_event_log/rtc_event_log_unittest_helper.cc",
]
deps = [
":rtc_event_log_impl",
":rtc_event_log_parser",
"../base:rtc_base_approved",
"../base:rtc_base_tests_utils",
"../call",
"../modules/rtp_rtcp",
"../system_wrappers:metrics_default",
"../test:test_support",
"//testing/gmock",
"//testing/gtest",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
rtc_test("rtc_event_log2rtp_dump") {
testonly = true
sources = [
"rtc_event_log/rtc_event_log2rtp_dump.cc",
]
deps = [
":rtc_event_log_api",
":rtc_event_log_impl",
":rtc_event_log_parser",
"../base:rtc_base_approved",
"../call:call_interfaces",
"../modules/rtp_rtcp:rtp_rtcp",
"../system_wrappers:field_trial_default",
"../system_wrappers:metrics_default",
"../test:rtp_test_utils",
"//third_party/gflags",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
}
if (rtc_include_tests) {
rtc_executable("rtc_event_log2text") {
testonly = true
sources = [
"rtc_event_log/rtc_event_log2text.cc",
]
deps = [
":rtc_event_log_api",
":rtc_event_log_impl",
":rtc_event_log_parser",
"../base:rtc_base_approved",
"../call:call_interfaces",
# TODO(kwiberg): Remove this dependency.
"../api/audio_codecs:audio_codecs_api",
"../modules/rtp_rtcp:rtp_rtcp",
"//third_party/gflags",
]
if (!build_with_chromium && is_clang) {
# Suppress warnings from the Chromium Clang plugin (bugs.webrtc.org/163).
suppressed_configs += [ "//build/config/clang:find_bad_constructs" ]
}
}
}
}