From 1140f97e4827b21212e9d8e622e7708b5bb2e29b Mon Sep 17 00:00:00 2001 From: mbonadei Date: Wed, 26 Apr 2017 03:38:35 -0700 Subject: [PATCH] Reland of Creating webrtc/modules:module_api (patchset #1 id:1 of https://codereview.webrtc.org/2839963005/ ) Reason for revert: Fixing the Gn error and try to reland. Original issue's description: > Revert of Creating webrtc/modules:module_api (patchset #5 id:80001 of https://codereview.webrtc.org/2838873002/ ) > > Reason for revert: > Causes build problem: https://build.chromium.org/p/client.webrtc/builders/iOS64%20Sim%20Debug%20%28iOS%209.0%29/builds/1630/steps/generate%20build%20files%20%28mb%29/logs/stdio > > Original issue's description: > > Creating webrtc/modules:module_api > > > > This target keeps track of .h the files under webrtc/modules/include/ > > that are not part of any target. > > If a .h file is not part of a target the 'gn check' utility is not > > able to spot if a target is missing a dependency because even if > > it parses '#include' directives it is not able to find a target that > > contains these headers. > > > > BUG=webrtc:7513 > > NOTRY=True > > > > Review-Url: https://codereview.webrtc.org/2838873002 > > Cr-Commit-Position: refs/heads/master@{#17880} > > Committed: https://chromium.googlesource.com/external/webrtc/+/5a1a092ed09ca92719eeb293275f64c0cdcc0e51 > > TBR=kjellander@webrtc.org > # Skipping CQ checks because original CL landed less than 1 days ago. > NOPRESUBMIT=true > NOTREECHECKS=true > NOTRY=true > BUG=webrtc:7513 > > Review-Url: https://codereview.webrtc.org/2839963005 > Cr-Commit-Position: refs/heads/master@{#17881} > Committed: https://chromium.googlesource.com/external/webrtc/+/bb08c3e29656fafe8a2d5d16ec4a62db49689f8a TBR=kjellander@webrtc.org # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true TBR=kjellander@webrtc.org BUG=webrtc:7513 Review-Url: https://codereview.webrtc.org/2843913002 Cr-Commit-Position: refs/heads/master@{#17884} --- webrtc/api/BUILD.gn | 1 + webrtc/audio/utility/BUILD.gn | 2 ++ webrtc/common_video/BUILD.gn | 1 + webrtc/modules/BUILD.gn | 17 ++++++++++++++--- webrtc/modules/audio_coding/BUILD.gn | 15 ++++++++++++++- webrtc/modules/audio_conference_mixer/BUILD.gn | 1 + webrtc/modules/audio_device/BUILD.gn | 1 + webrtc/modules/audio_mixer/BUILD.gn | 3 +++ webrtc/modules/audio_processing/BUILD.gn | 4 ++++ webrtc/modules/congestion_controller/BUILD.gn | 1 + webrtc/modules/media_file/BUILD.gn | 1 + webrtc/modules/pacing/BUILD.gn | 1 + .../modules/remote_bitrate_estimator/BUILD.gn | 1 + webrtc/modules/rtp_rtcp/BUILD.gn | 4 ++++ webrtc/modules/utility/BUILD.gn | 2 ++ webrtc/modules/video_capture/BUILD.gn | 1 + webrtc/modules/video_coding/BUILD.gn | 5 +++++ webrtc/modules/video_processing/BUILD.gn | 4 ++++ webrtc/sdk/BUILD.gn | 1 + webrtc/tools/BUILD.gn | 2 ++ webrtc/video/BUILD.gn | 2 ++ webrtc/voice_engine/BUILD.gn | 7 +++++++ 22 files changed, 73 insertions(+), 4 deletions(-) diff --git a/webrtc/api/BUILD.gn b/webrtc/api/BUILD.gn index b8ad90505f..3fa61a51b1 100644 --- a/webrtc/api/BUILD.gn +++ b/webrtc/api/BUILD.gn @@ -156,6 +156,7 @@ rtc_source_set("audio_mixer_api") { deps = [ "../base:rtc_base_approved", + "../modules:module_api", ] } diff --git a/webrtc/audio/utility/BUILD.gn b/webrtc/audio/utility/BUILD.gn index 2ef5eba338..ac477e4f25 100644 --- a/webrtc/audio/utility/BUILD.gn +++ b/webrtc/audio/utility/BUILD.gn @@ -22,6 +22,7 @@ rtc_static_library("audio_frame_operations") { deps = [ "../..:webrtc_common", "../../base:rtc_base_approved", + "../../modules:module_api", "../../modules/audio_coding:audio_format_conversion", ] } @@ -35,6 +36,7 @@ if (rtc_include_tests) { deps = [ ":audio_frame_operations", "../../base:rtc_base_approved", + "../../modules:module_api", "../../test:test_support", "//testing/gtest", ] diff --git a/webrtc/common_video/BUILD.gn b/webrtc/common_video/BUILD.gn index 152f98b089..6b7eb01400 100644 --- a/webrtc/common_video/BUILD.gn +++ b/webrtc/common_video/BUILD.gn @@ -59,6 +59,7 @@ rtc_static_library("common_video") { "..:webrtc_common", "../base:rtc_base", "../base:rtc_task_queue", + "../modules:module_api", "../system_wrappers", ] public_deps = [ diff --git a/webrtc/modules/BUILD.gn b/webrtc/modules/BUILD.gn index e750a81097..b6978258da 100644 --- a/webrtc/modules/BUILD.gn +++ b/webrtc/modules/BUILD.gn @@ -29,6 +29,18 @@ group("modules") { ] } +rtc_source_set("module_api") { + sources = [ + "include/module.h", + "include/module_common_types.h", + ] + deps = [ + "..:webrtc_common", + "../api:video_frame_api", + "../base:rtc_base_approved", + ] +} + if (rtc_include_tests) { modules_tests_resources = [ "//resources/audio_coding/testfile32kHz.pcm", @@ -199,8 +211,6 @@ if (rtc_include_tests) { rtc_test("modules_unittests") { testonly = true - - deps = [] defines = [] sources = [ "module_common_types_unittest.cc", @@ -211,7 +221,8 @@ if (rtc_include_tests) { suppressed_configs += [ "//build/config/clang:find_bad_constructs" ] } - deps += [ + deps = [ + ":module_api", "../test:test_main", "audio_coding:audio_coding_unittests", "audio_conference_mixer:audio_conference_mixer_unittests", diff --git a/webrtc/modules/audio_coding/BUILD.gn b/webrtc/modules/audio_coding/BUILD.gn index 4a2fdcaf87..8195e47aa6 100644 --- a/webrtc/modules/audio_coding/BUILD.gn +++ b/webrtc/modules/audio_coding/BUILD.gn @@ -127,6 +127,7 @@ rtc_source_set("audio_coding_module_typedefs") { "include/audio_coding_module_typedefs.h", ] deps = [ + "..:module_api", "../..:webrtc_common", ] } @@ -163,6 +164,7 @@ rtc_static_library("audio_coding") { } deps = audio_coding_deps + [ + "..:module_api", "../../api/audio_codecs:audio_codecs_api", "../../api/audio_codecs:builtin_audio_decoder_factory", ":audio_coding_module_typedefs", @@ -1067,6 +1069,7 @@ rtc_static_library("neteq") { ":isac_fix", ":neteq_decoder_enum", ":pcm16b", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:audio_codecs_api", "../../base:gtest_prod", @@ -1198,6 +1201,7 @@ if (rtc_include_tests) { ":audio_coding_module_typedefs", ":audio_format_conversion", ":pcm16b_c", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:builtin_audio_decoder_factory", "../../base:rtc_base_approved", @@ -1301,6 +1305,7 @@ if (rtc_include_tests) { ":audio_coding", ":audio_coding_module_typedefs", ":audio_format_conversion", + "..:module_api", "../../:webrtc_common", "../../base:rtc_base_approved", "../../system_wrappers", @@ -1328,6 +1333,7 @@ if (rtc_include_tests) { deps = [ ":audio_coding", ":audio_format_conversion", + "..:module_api", "../../:webrtc_common", "../../base:rtc_base_approved", "../../system_wrappers", @@ -1429,7 +1435,9 @@ if (rtc_include_tests) { rtc_test("neteq_rtpplay") { testonly = true defines = [] - deps = [] + deps = [ + "..:module_api", + ] sources = [ "neteq/tools/neteq_rtpplay.cc", ] @@ -1509,6 +1517,7 @@ if (rtc_include_tests) { ":neteq", ":neteq_unittest_tools", ":pcm16b", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:audio_codecs_api", "../../api/audio_codecs:builtin_audio_decoder_factory", @@ -1534,6 +1543,7 @@ if (rtc_include_tests) { deps = [ ":neteq", ":neteq_unittest_tools", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:builtin_audio_decoder_factory", "../../base:rtc_base_approved", @@ -1588,6 +1598,7 @@ if (rtc_include_tests) { deps = [ ":audio_encoder_interface", ":pcm16b", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:audio_codecs_api", "../../base:rtc_base_approved", @@ -1625,6 +1636,7 @@ if (rtc_include_tests) { ":ilbc", ":isac", ":pcm16b", + "..:module_api", "../..:webrtc_common", "//testing/gtest", ] @@ -2136,6 +2148,7 @@ if (rtc_include_tests) { ":red", ":rent_a_codec", ":webrtc_opus", + "..:module_api", "../..:webrtc_common", "../../api/audio_codecs:audio_codecs_api", "../../api/audio_codecs:builtin_audio_decoder_factory", diff --git a/webrtc/modules/audio_conference_mixer/BUILD.gn b/webrtc/modules/audio_conference_mixer/BUILD.gn index fc9904c23b..8939da222e 100644 --- a/webrtc/modules/audio_conference_mixer/BUILD.gn +++ b/webrtc/modules/audio_conference_mixer/BUILD.gn @@ -39,6 +39,7 @@ rtc_static_library("audio_conference_mixer") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../audio/utility:audio_frame_operations", "../../base:rtc_base_approved", diff --git a/webrtc/modules/audio_device/BUILD.gn b/webrtc/modules/audio_device/BUILD.gn index 1e691fa9bc..ab0b4f5b32 100644 --- a/webrtc/modules/audio_device/BUILD.gn +++ b/webrtc/modules/audio_device/BUILD.gn @@ -49,6 +49,7 @@ rtc_static_library("audio_device") { public_configs = [ ":audio_device_config" ] deps = [ + "..:module_api", "../..:webrtc_common", "../../base:rtc_base_approved", "../../base:rtc_task_queue", diff --git a/webrtc/modules/audio_mixer/BUILD.gn b/webrtc/modules/audio_mixer/BUILD.gn index d8acc05a4a..cd3b768ee1 100644 --- a/webrtc/modules/audio_mixer/BUILD.gn +++ b/webrtc/modules/audio_mixer/BUILD.gn @@ -38,6 +38,7 @@ rtc_static_library("audio_mixer_impl") { deps = [ ":audio_frame_manipulator", + "..:module_api", "../..:webrtc_common", "../../audio/utility:audio_frame_operations", "../../base:rtc_base_approved", @@ -58,6 +59,7 @@ rtc_static_library("audio_frame_manipulator") { ] deps = [ + "..:module_api", "../../audio/utility", "../../base:rtc_base_approved", ] @@ -85,6 +87,7 @@ if (rtc_include_tests) { deps = [ ":audio_frame_manipulator", ":audio_mixer_impl", + "..:module_api", "../../api:audio_mixer_api", "../../audio/utility:audio_frame_operations", "../../base:rtc_base", diff --git a/webrtc/modules/audio_processing/BUILD.gn b/webrtc/modules/audio_processing/BUILD.gn index 0f6de09052..ff9a4d6474 100644 --- a/webrtc/modules/audio_processing/BUILD.gn +++ b/webrtc/modules/audio_processing/BUILD.gn @@ -230,6 +230,7 @@ rtc_static_library("audio_processing") { defines = [] deps = [ + "..:module_api", "../..:webrtc_common", "../../audio/utility:audio_frame_operations", "../../base:gtest_prod", @@ -531,6 +532,7 @@ if (rtc_include_tests) { deps = [ ":audio_processing", ":audioproc_test_utils", + "..:module_api", "../..:webrtc_common", "../../base:gtest_prod", "../../base:protobuf_utils", @@ -749,6 +751,7 @@ if (rtc_include_tests) { deps = [ ":audio_processing", + "..:module_api", "../../base:rtc_base_approved", "../../common_audio", "../../system_wrappers:system_wrappers", @@ -764,6 +767,7 @@ if (rtc_include_tests) { ] deps = [ ":audio_processing", + "..:module_api", "../..:webrtc_common", "../../common_audio:common_audio", "../../system_wrappers:metrics_default", diff --git a/webrtc/modules/congestion_controller/BUILD.gn b/webrtc/modules/congestion_controller/BUILD.gn index 647079a382..3dcbb27b24 100644 --- a/webrtc/modules/congestion_controller/BUILD.gn +++ b/webrtc/modules/congestion_controller/BUILD.gn @@ -45,6 +45,7 @@ rtc_static_library("congestion_controller") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../base:rtc_base", "../../base:rtc_base_approved", diff --git a/webrtc/modules/media_file/BUILD.gn b/webrtc/modules/media_file/BUILD.gn index 4f8fbbc4e2..7ab897f28f 100644 --- a/webrtc/modules/media_file/BUILD.gn +++ b/webrtc/modules/media_file/BUILD.gn @@ -33,6 +33,7 @@ rtc_static_library("media_file") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../base:rtc_base_approved", "../../common_audio", diff --git a/webrtc/modules/pacing/BUILD.gn b/webrtc/modules/pacing/BUILD.gn index ce2356e28a..57126d7143 100644 --- a/webrtc/modules/pacing/BUILD.gn +++ b/webrtc/modules/pacing/BUILD.gn @@ -26,6 +26,7 @@ rtc_static_library("pacing") { } deps = [ + "..:module_api", "../../:webrtc_common", "../../base:rtc_base_approved", "../../logging:rtc_event_log_api", diff --git a/webrtc/modules/remote_bitrate_estimator/BUILD.gn b/webrtc/modules/remote_bitrate_estimator/BUILD.gn index c2e5d31492..04f2f7cc55 100644 --- a/webrtc/modules/remote_bitrate_estimator/BUILD.gn +++ b/webrtc/modules/remote_bitrate_estimator/BUILD.gn @@ -109,6 +109,7 @@ if (rtc_include_tests) { deps = [ ":remote_bitrate_estimator", + "..:module_api", "../..:webrtc_common", "../../base:gtest_prod", "../../base:rtc_base", diff --git a/webrtc/modules/rtp_rtcp/BUILD.gn b/webrtc/modules/rtp_rtcp/BUILD.gn index a369218a68..5d754d9974 100644 --- a/webrtc/modules/rtp_rtcp/BUILD.gn +++ b/webrtc/modules/rtp_rtcp/BUILD.gn @@ -166,6 +166,7 @@ rtc_static_library("rtp_rtcp") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../api:libjingle_peerconnection_api", "../../api:transport_api", @@ -200,6 +201,7 @@ rtc_source_set("fec_test_helper") { ] deps = [ ":rtp_rtcp", + "..:module_api", "../../base:rtc_base_approved", ] @@ -257,6 +259,7 @@ if (rtc_include_tests) { ] deps = [ ":rtp_rtcp", + "..:module_api", "../../base:rtc_base_approved", "../../test:test_support", ] @@ -336,6 +339,7 @@ if (rtc_include_tests) { ":fec_test_helper", ":mock_rtp_rtcp", ":rtp_rtcp", + "..:module_api", "../..:webrtc_common", "../../api:transport_api", "../../base:rtc_base_approved", diff --git a/webrtc/modules/utility/BUILD.gn b/webrtc/modules/utility/BUILD.gn index 3d32ac27d5..71238905dc 100644 --- a/webrtc/modules/utility/BUILD.gn +++ b/webrtc/modules/utility/BUILD.gn @@ -30,6 +30,7 @@ rtc_static_library("utility") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../audio/utility:audio_frame_operations", "../../base:rtc_task_queue", @@ -54,6 +55,7 @@ if (rtc_include_tests) { ] deps = [ ":utility", + "..:module_api", "../../base:rtc_task_queue", "../../test:test_support", "//testing/gmock", diff --git a/webrtc/modules/video_capture/BUILD.gn b/webrtc/modules/video_capture/BUILD.gn index b7482a2555..c902ee86ff 100644 --- a/webrtc/modules/video_capture/BUILD.gn +++ b/webrtc/modules/video_capture/BUILD.gn @@ -26,6 +26,7 @@ rtc_static_library("video_capture_module") { ] deps = [ + "..:module_api", "../..:webrtc_common", "../../base:rtc_base_approved", "../../common_video", diff --git a/webrtc/modules/video_coding/BUILD.gn b/webrtc/modules/video_coding/BUILD.gn index bafc8bae07..477e06444e 100644 --- a/webrtc/modules/video_coding/BUILD.gn +++ b/webrtc/modules/video_coding/BUILD.gn @@ -94,6 +94,7 @@ rtc_static_library("video_coding") { ":webrtc_i420", ":webrtc_vp8", ":webrtc_vp9", + "..:module_api", "../..:video_stream_api", "../..:webrtc_common", "../../base:rtc_base", @@ -129,6 +130,7 @@ rtc_static_library("video_coding_utility") { } deps = [ + "..:module_api", "../..:webrtc_common", "../../api/video_codecs:video_codecs_api", "../../base:rtc_base_approved", @@ -225,6 +227,7 @@ rtc_static_library("webrtc_vp8") { deps = [ ":video_coding_utility", + "..:module_api", "../..:webrtc_common", "../../api/video_codecs:video_codecs_api", "../../base:rtc_base_approved", @@ -260,6 +263,7 @@ rtc_static_library("webrtc_vp9") { deps = [ ":video_coding_utility", + "..:module_api", "../../base:rtc_base_approved", "../../common_video", "../../system_wrappers", @@ -543,6 +547,7 @@ if (rtc_include_tests) { ":webrtc_h264", ":webrtc_vp8", ":webrtc_vp9", + "..:module_api", "../..:webrtc_common", "../../api:video_frame_api", "../../api/video_codecs:video_codecs_api", diff --git a/webrtc/modules/video_processing/BUILD.gn b/webrtc/modules/video_processing/BUILD.gn index 7c9391a6d4..c4c9c3b894 100644 --- a/webrtc/modules/video_processing/BUILD.gn +++ b/webrtc/modules/video_processing/BUILD.gn @@ -26,6 +26,7 @@ rtc_static_library("video_processing") { deps = [ ":denoiser_filter", + "..:module_api", "../../base:rtc_base_approved", "../../common_audio", "../../common_video", @@ -51,6 +52,9 @@ rtc_source_set("denoiser_filter") { sources = [ "util/denoiser_filter.h", ] + deps = [ + "..:module_api", + ] } if (build_video_processing_sse2) { diff --git a/webrtc/sdk/BUILD.gn b/webrtc/sdk/BUILD.gn index 8aabcf14ee..b58fa98440 100644 --- a/webrtc/sdk/BUILD.gn +++ b/webrtc/sdk/BUILD.gn @@ -425,6 +425,7 @@ if (is_ios || is_mac) { "../base:rtc_base_approved", "../common_video", "../media:rtc_media_base", + "../modules:module_api", "../modules/video_coding:video_coding_utility", "../modules/video_coding:webrtc_h264", "../system_wrappers", diff --git a/webrtc/tools/BUILD.gn b/webrtc/tools/BUILD.gn index be3296d1ff..2850552f1a 100644 --- a/webrtc/tools/BUILD.gn +++ b/webrtc/tools/BUILD.gn @@ -210,6 +210,7 @@ if (rtc_enable_protobuf) { "../call:call_interfaces", "../logging:rtc_event_log_impl", "../logging:rtc_event_log_parser", + "../modules:module_api", "../modules/audio_coding:ana_debug_dump_proto", # TODO(kwiberg): Remove this dependency. @@ -261,6 +262,7 @@ if (rtc_include_tests) { } deps = [ + "../modules:module_api", "../modules/audio_processing", "../system_wrappers:metrics_default", "../test:test_support", diff --git a/webrtc/video/BUILD.gn b/webrtc/video/BUILD.gn index 76f6ece715..61d628ad74 100644 --- a/webrtc/video/BUILD.gn +++ b/webrtc/video/BUILD.gn @@ -65,6 +65,7 @@ rtc_static_library("video") { "../common_video", "../logging:rtc_event_log_api", "../media:rtc_media_base", + "../modules:module_api", "../modules/bitrate_controller", "../modules/congestion_controller", "../modules/pacing", @@ -260,6 +261,7 @@ if (rtc_include_tests) { "../logging:rtc_event_log_api", "../media:rtc_media_base", "../media:rtc_media_tests_utils", + "../modules:module_api", "../modules/pacing", "../modules/rtp_rtcp", "../modules/rtp_rtcp:mock_rtp_rtcp", diff --git a/webrtc/voice_engine/BUILD.gn b/webrtc/voice_engine/BUILD.gn index ca774f2800..be6faabe39 100644 --- a/webrtc/voice_engine/BUILD.gn +++ b/webrtc/voice_engine/BUILD.gn @@ -16,6 +16,7 @@ rtc_static_library("audio_coder") { deps = [ "..:webrtc_common", "../api/audio_codecs:builtin_audio_decoder_factory", + "../modules:module_api", "../modules/audio_coding", "../modules/audio_coding:audio_encoder_factory_interface", "../modules/audio_coding:audio_format_conversion", @@ -39,6 +40,7 @@ rtc_static_library("file_player") { "..:webrtc_common", "../base:rtc_base_approved", "../common_audio", + "../modules:module_api", "../modules/media_file", ] @@ -58,6 +60,7 @@ rtc_static_library("file_recorder") { "..:webrtc_common", "../base:rtc_base_approved", "../common_audio", + "../modules:module_api", "../modules/media_file:media_file", "../system_wrappers", ] @@ -141,6 +144,7 @@ rtc_static_library("voice_engine") { "../audio/utility:audio_frame_operations", "../base:rtc_base_approved", "../base:rtc_task_queue", + "../modules:module_api", # TODO(nisse): Delete when declaration of RtpTransportController # and related interfaces move to api/. @@ -172,6 +176,7 @@ rtc_static_library("audio_level") { "..:webrtc_common", "../base:rtc_base_approved", "../common_audio", + "../modules:module_api", ] } @@ -181,6 +186,7 @@ if (rtc_include_tests) { ":file_player", ":voice_engine", "../base:rtc_base_approved", + "../modules:module_api", "../test:test_common", "//testing/gmock", "//testing/gtest", @@ -244,6 +250,7 @@ if (rtc_include_tests) { ":voice_engine", "..:webrtc_common", "../base:rtc_base_approved", + "../modules:module_api", "../modules/audio_device:audio_device", "../modules/audio_processing:audio_processing", "../modules/rtp_rtcp:rtp_rtcp",