Including libyuv headers using fully qualified paths.

Using fully qualified paths to include libyuv headers allows WebRTC to
avoid to rely on the //third_party/libyuv:libyuv_config target to
set the -I compiler flag.

Today some WebRTC targets depend on //third_party/libyuv only to
include //third_party/libyuv:libyuv_config but with fully qualified
paths this should not be needed anymore.

A follow-up CL will remove //third_party/libyuv from some targets that
don't need it because they are not including libyuv headers.

Bug: webrtc:8605
Change-Id: Icec707ca761aaf2ea8088e7f7a05ddde0de2619a
No-Try: True
Reviewed-on: https://webrtc-review.googlesource.com/28220
Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org>
Reviewed-by: Magnus Flodman <mflodman@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#21209}
This commit is contained in:
Mirko Bonadei 2017-12-11 09:32:13 +01:00 committed by Commit Bot
parent d4d399081b
commit 654320666d
28 changed files with 39 additions and 35 deletions

1
.gn
View file

@ -42,6 +42,7 @@ check_targets = [
"//test/*", "//test/*",
"//video/*", "//video/*",
"//voice_engine/*", "//voice_engine/*",
"//third_party/libyuv/*",
] ]
# These are the list of GN files that run exec_script. This whitelist exists # These are the list of GN files that run exec_script. This whitelist exists

View file

@ -14,11 +14,11 @@
#include <algorithm> #include <algorithm>
#include <utility> #include <utility>
#include "libyuv/convert.h"
#include "libyuv/planar_functions.h"
#include "libyuv/scale.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/keep_ref_until_done.h" #include "rtc_base/keep_ref_until_done.h"
#include "third_party/libyuv/include/libyuv/convert.h"
#include "third_party/libyuv/include/libyuv/planar_functions.h"
#include "third_party/libyuv/include/libyuv/scale.h"
// Aligning pointer to 64 bytes for improved performance, e.g. use SIMD. // Aligning pointer to 64 bytes for improved performance, e.g. use SIMD.
static const int kBufferAlignment = 64; static const int kBufferAlignment = 64;

View file

@ -3,4 +3,5 @@ include_rules = [
"+system_wrappers", "+system_wrappers",
# TODO(magjed): This is temporary, remove once external clients are updated. # TODO(magjed): This is temporary, remove once external clients are updated.
"+sdk/objc", "+sdk/objc",
"+third_party/libyuv",
] ]

View file

@ -16,11 +16,11 @@
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "api/video/video_frame.h" #include "api/video/video_frame.h"
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "libyuv.h" // NOLINT
#include "test/frame_utils.h" #include "test/frame_utils.h"
#include "test/gmock.h" #include "test/gmock.h"
#include "test/gtest.h" #include "test/gtest.h"
#include "test/testsupport/fileutils.h" #include "test/testsupport/fileutils.h"
#include "third_party/libyuv/include/libyuv.h"
namespace webrtc { namespace webrtc {

View file

@ -12,11 +12,9 @@
#include <string.h> #include <string.h>
#include "rtc_base/checks.h"
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "rtc_base/checks.h"
// NOTE(ajm): Path provided by gn. #include "third_party/libyuv/include/libyuv.h"
#include "libyuv.h" // NOLINT
namespace webrtc { namespace webrtc {

View file

@ -14,11 +14,11 @@
#include <algorithm> #include <algorithm>
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "libyuv/convert.h"
#include "libyuv/planar_functions.h"
#include "libyuv/scale.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/keep_ref_until_done.h" #include "rtc_base/keep_ref_until_done.h"
#include "third_party/libyuv/include/libyuv/convert.h"
#include "third_party/libyuv/include/libyuv/planar_functions.h"
#include "third_party/libyuv/include/libyuv/scale.h"
namespace webrtc { namespace webrtc {

View file

@ -6,4 +6,5 @@ include_rules = [
"+modules/video_capture", "+modules/video_capture",
"+p2p", "+p2p",
"+pc", "+pc",
"+third_party/libyuv",
] ]

View file

@ -14,12 +14,12 @@
#include <gtk/gtk.h> #include <gtk/gtk.h>
#include <stddef.h> #include <stddef.h>
#include "libyuv/convert_from.h"
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "examples/peerconnection/client/defaults.h" #include "examples/peerconnection/client/defaults.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/logging.h" #include "rtc_base/logging.h"
#include "rtc_base/stringutils.h" #include "rtc_base/stringutils.h"
#include "third_party/libyuv/include/libyuv/convert_from.h"
using rtc::sprintfn; using rtc::sprintfn;

View file

@ -12,12 +12,12 @@
#include <math.h> #include <math.h>
#include "libyuv/convert_argb.h"
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "examples/peerconnection/client/defaults.h" #include "examples/peerconnection/client/defaults.h"
#include "rtc_base/arraysize.h" #include "rtc_base/arraysize.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/logging.h" #include "rtc_base/logging.h"
#include "third_party/libyuv/include/libyuv/convert_argb.h"
ATOM MainWnd::wnd_class_ = 0; ATOM MainWnd::wnd_class_ = 0;
const wchar_t MainWnd::kClassName[] = L"WebRTC_MainWnd"; const wchar_t MainWnd::kClassName[] = L"WebRTC_MainWnd";

View file

@ -16,6 +16,7 @@ include_rules = [
"+system_wrappers", "+system_wrappers",
"+voice_engine", "+voice_engine",
"+usrsctplib", "+usrsctplib",
"+third_party/libyuv",
] ]
specific_include_rules = { specific_include_rules = {

View file

@ -12,8 +12,6 @@
#include <algorithm> #include <algorithm>
// NOTE(ajm): Path provided by gyp.
#include "libyuv/scale.h" // NOLINT
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "api/video_codecs/video_encoder_factory.h" #include "api/video_codecs/video_encoder_factory.h"
@ -22,6 +20,7 @@
#include "modules/video_coding/codecs/vp8/simulcast_rate_allocator.h" #include "modules/video_coding/codecs/vp8/simulcast_rate_allocator.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "system_wrappers/include/clock.h" #include "system_wrappers/include/clock.h"
#include "third_party/libyuv/include/libyuv/scale.h"
namespace { namespace {

View file

@ -2,4 +2,5 @@ include_rules = [
"+common_video", "+common_video",
"+media/base", "+media/base",
"+system_wrappers", "+system_wrappers",
"+third_party/libyuv",
] ]

View file

@ -8,21 +8,20 @@
* be found in the AUTHORS file in the root of the source tree. * be found in the AUTHORS file in the root of the source tree.
*/ */
#include "modules/video_capture/video_capture_impl.h"
#include <stdlib.h> #include <stdlib.h>
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "libyuv.h" // NOLINT
#include "modules/include/module_common_types.h" #include "modules/include/module_common_types.h"
#include "modules/video_capture/video_capture_config.h" #include "modules/video_capture/video_capture_config.h"
#include "modules/video_capture/video_capture_impl.h"
#include "rtc_base/logging.h" #include "rtc_base/logging.h"
#include "rtc_base/refcount.h" #include "rtc_base/refcount.h"
#include "rtc_base/refcountedobject.h" #include "rtc_base/refcountedobject.h"
#include "rtc_base/timeutils.h" #include "rtc_base/timeutils.h"
#include "rtc_base/trace_event.h" #include "rtc_base/trace_event.h"
#include "system_wrappers/include/clock.h" #include "system_wrappers/include/clock.h"
#include "third_party/libyuv/include/libyuv.h"
namespace webrtc { namespace webrtc {
namespace videocapturemodule { namespace videocapturemodule {

View file

@ -4,6 +4,7 @@ include_rules = [
"+common_video", "+common_video",
"+system_wrappers", "+system_wrappers",
"+rtc_tools", "+rtc_tools",
"+third_party/libyuv",
] ]
specific_include_rules = { specific_include_rules = {

View file

@ -15,7 +15,7 @@
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "libyuv.h" // NOLINT #include "third_party/libyuv/include/libyuv.h"
namespace { namespace {
const size_t kI420HeaderSize = 4; const size_t kI420HeaderSize = 4;

View file

@ -16,10 +16,6 @@
#include <algorithm> #include <algorithm>
#include <string> #include <string>
// NOTE(ajm): Path provided by gyp.
#include "libyuv/convert.h" // NOLINT
#include "libyuv/scale.h" // NOLINT
#include "common_types.h" // NOLINT(build/include) #include "common_types.h" // NOLINT(build/include)
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "modules/include/module_common_types.h" #include "modules/include/module_common_types.h"
@ -37,6 +33,8 @@
#include "system_wrappers/include/clock.h" #include "system_wrappers/include/clock.h"
#include "system_wrappers/include/field_trial.h" #include "system_wrappers/include/field_trial.h"
#include "system_wrappers/include/metrics.h" #include "system_wrappers/include/metrics.h"
#include "third_party/libyuv/include/libyuv/convert.h"
#include "third_party/libyuv/include/libyuv/scale.h"
namespace webrtc { namespace webrtc {
namespace { namespace {

View file

@ -2,4 +2,5 @@ include_rules = [
"+common_audio", "+common_audio",
"+common_video", "+common_video",
"+system_wrappers", "+system_wrappers",
"+third_party/libyuv",
] ]

View file

@ -8,9 +8,9 @@
* be found in the AUTHORS file in the root of the source tree. * be found in the AUTHORS file in the root of the source tree.
*/ */
#include "common_video/libyuv/include/webrtc_libyuv.h"
#include "modules/video_processing/video_denoiser.h" #include "modules/video_processing/video_denoiser.h"
#include "libyuv/planar_functions.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "third_party/libyuv/include/libyuv/planar_functions.h"
namespace webrtc { namespace webrtc {

View file

@ -12,5 +12,6 @@ include_rules = [
"+modules/rtp_rtcp", "+modules/rtp_rtcp",
"+system_wrappers", "+system_wrappers",
"+p2p", "+p2p",
"+third_party/libyuv",
] ]

View file

@ -13,8 +13,8 @@
#include <string> #include <string>
#include "libyuv/compare.h" // NOLINT #include "third_party/libyuv/include/libyuv/compare.h"
#include "libyuv/convert.h" // NOLINT #include "third_party/libyuv/include/libyuv/convert.h"
namespace webrtc { namespace webrtc {
namespace test { namespace test {

View file

@ -15,8 +15,8 @@
#include <vector> #include <vector>
#include <utility> #include <utility>
#include "libyuv/compare.h" // NOLINT #include "third_party/libyuv/include/libyuv/compare.h"
#include "libyuv/convert.h" // NOLINT #include "third_party/libyuv/include/libyuv/convert.h"
namespace webrtc { namespace webrtc {
namespace test { namespace test {

View file

@ -13,7 +13,6 @@
#include <memory> #include <memory>
#include "common_video/include/video_frame_buffer.h" #include "common_video/include/video_frame_buffer.h"
#include "libyuv/scale.h"
#include "rtc_base/bind.h" #include "rtc_base/bind.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/keep_ref_until_done.h" #include "rtc_base/keep_ref_until_done.h"
@ -25,6 +24,7 @@
#include "sdk/android/src/jni/jni_helpers.h" #include "sdk/android/src/jni/jni_helpers.h"
#include "sdk/android/src/jni/wrapped_native_i420_buffer.h" #include "sdk/android/src/jni/wrapped_native_i420_buffer.h"
#include "system_wrappers/include/aligned_malloc.h" #include "system_wrappers/include/aligned_malloc.h"
#include "third_party/libyuv/include/libyuv/scale.h"
namespace webrtc { namespace webrtc {
namespace jni { namespace jni {

View file

@ -17,4 +17,5 @@ include_rules = [
"+system_wrappers", "+system_wrappers",
"+modules/audio_device", "+modules/audio_device",
"+modules/audio_processing", "+modules/audio_processing",
"+third_party/libyuv",
] ]

View file

@ -14,7 +14,7 @@
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/logging.h" #include "rtc_base/logging.h"
#include "libyuv.h" #include "third_party/libyuv/include/libyuv.h"
@implementation RTCCVPixelBuffer { @implementation RTCCVPixelBuffer {
int _width; int _width;

View file

@ -10,11 +10,11 @@
#include "sdk/objc/Framework/Classes/Video/corevideo_frame_buffer.h" #include "sdk/objc/Framework/Classes/Video/corevideo_frame_buffer.h"
#include "libyuv/convert.h"
#include "api/video/i420_buffer.h" #include "api/video/i420_buffer.h"
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "rtc_base/checks.h" #include "rtc_base/checks.h"
#include "rtc_base/logging.h" #include "rtc_base/logging.h"
#include "third_party/libyuv/include/libyuv/convert.h"
namespace webrtc { namespace webrtc {

View file

@ -22,11 +22,10 @@
#import "WebRTC/RTCVideoCodec.h" #import "WebRTC/RTCVideoCodec.h"
#import "WebRTC/RTCVideoFrame.h" #import "WebRTC/RTCVideoFrame.h"
#import "WebRTC/RTCVideoFrameBuffer.h" #import "WebRTC/RTCVideoFrameBuffer.h"
#import "helpers.h"
#include "libyuv/convert_from.h"
#include "common_video/h264/h264_bitstream_parser.h" #include "common_video/h264/h264_bitstream_parser.h"
#include "common_video/h264/profile_level_id.h" #include "common_video/h264/profile_level_id.h"
#include "common_video/include/bitrate_adjuster.h" #include "common_video/include/bitrate_adjuster.h"
#import "helpers.h"
#include "modules/include/module_common_types.h" #include "modules/include/module_common_types.h"
#include "modules/video_coding/include/video_error_codes.h" #include "modules/video_coding/include/video_error_codes.h"
#include "rtc_base/buffer.h" #include "rtc_base/buffer.h"
@ -34,6 +33,7 @@
#include "rtc_base/timeutils.h" #include "rtc_base/timeutils.h"
#include "sdk/objc/Framework/Classes/VideoToolbox/nalu_rewriter.h" #include "sdk/objc/Framework/Classes/VideoToolbox/nalu_rewriter.h"
#include "system_wrappers/include/clock.h" #include "system_wrappers/include/clock.h"
#include "third_party/libyuv/include/libyuv/convert_from.h"
@interface RTCVideoEncoderH264 () @interface RTCVideoEncoderH264 ()

View file

@ -17,6 +17,7 @@ include_rules = [
"+sdk", "+sdk",
"+system_wrappers", "+system_wrappers",
"+voice_engine", "+voice_engine",
"+third_party/libyuv",
] ]
specific_include_rules = { specific_include_rules = {

View file

@ -20,7 +20,7 @@
#include "api/video/video_frame.h" #include "api/video/video_frame.h"
#include "common_video/libyuv/include/webrtc_libyuv.h" #include "common_video/libyuv/include/webrtc_libyuv.h"
#include "test/frame_utils.h" #include "test/frame_utils.h"
#include "libyuv/convert.h" #include "third_party/libyuv/include/libyuv/convert.h"
namespace webrtc { namespace webrtc {
namespace test { namespace test {