Restructure GYP for vp9, opus and direct trace

This is needed to make the build more flexible for some use cases.

BUG=4185
R=andresp@webrtc.org, stefan@webrtc.org, tommi@webrtc.org

Review URL: https://webrtc-codereview.appspot.com/34099004

Cr-Commit-Position: refs/heads/master@{#8290}
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8290 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
kjellander@webrtc.org 2015-02-09 10:01:17 +00:00
parent f31f56d8d4
commit 2b69eab077
8 changed files with 50 additions and 11 deletions

View File

@ -41,6 +41,7 @@
'webrtc_vp8_dir%': '<(webrtc_root)/modules/video_coding/codecs/vp8',
'webrtc_vp9_dir%': '<(webrtc_root)/modules/video_coding/codecs/vp9',
'include_opus%': 1,
'opus_dir%': '<(DEPTH)/third_party/opus',
},
'build_with_chromium%': '<(build_with_chromium)',
'build_with_libjingle%': '<(build_with_libjingle)',
@ -92,6 +93,7 @@
'build_libjpeg%': 1,
'build_libyuv%': 1,
'build_libvpx%': 1,
'build_vp9%': 1,
'build_ssl%': 1,
# Disable by default
@ -100,7 +102,10 @@
# Enable to use the Mozilla internal settings.
'build_with_mozilla%': 0,
# Make it possible to provide custom locations for some libraries.
'libvpx_dir%': '<(DEPTH)/third_party/libvpx',
'libyuv_dir%': '<(DEPTH)/third_party/libyuv',
'opus_dir%': '<(opus_dir)',
# Define MIPS architecture variant, MIPS DSP variant and MIPS FPU
# This may be subject to change in accordance to Chromium's MIPS flags
@ -122,6 +127,10 @@
# enable schannel on windows.
'use_legacy_ssl_defaults%': 0,
# Directly call the trace callback instead of passing it to a logging
# thread. Used for components that provide their own threaded logging.
'rtc_use_direct_trace%': 0,
'conditions': [
['build_with_chromium==1', {
# Exclude pulse audio on Chromium since its prerequisites don't require

View File

@ -19,7 +19,7 @@
]
}, {
'dependencies': [
'<(DEPTH)/third_party/opus/opus.gyp:opus'
'<(opus_dir)/opus.gyp:opus'
],
}],
],

View File

@ -26,7 +26,7 @@
],
'neteq_dependencies': [
'<@(codecs)',
'<(DEPTH)/third_party/opus/opus.gyp:opus',
'<(opus_dir)/opus.gyp:opus',
'<(webrtc_root)/common_audio/common_audio.gyp:common_audio',
'<(webrtc_root)/system_wrappers/system_wrappers.gyp:system_wrappers',
'audio_decoder_interface',
@ -55,7 +55,7 @@
],
},
'export_dependent_settings': [
'<(DEPTH)/third_party/opus/opus.gyp:opus',
'<(opus_dir)/opus.gyp:opus',
],
'sources': [
'interface/neteq.h',

View File

@ -326,7 +326,7 @@
}],
['build_libvpx==1', {
'dependencies': [
'<(DEPTH)/third_party/libvpx/libvpx.gyp:libvpx',
'<(libvpx_dir)/libvpx.gyp:libvpx',
],
}],
['OS=="android"', {

View File

@ -22,7 +22,7 @@
'conditions': [
['build_libvpx==1', {
'dependencies': [
'<(DEPTH)/third_party/libvpx/libvpx.gyp:libvpx',
'<(libvpx_dir)/libvpx.gyp:libvpx',
],
}],
],

View File

@ -22,15 +22,21 @@
'conditions': [
['build_libvpx==1', {
'dependencies': [
'<(DEPTH)/third_party/libvpx/libvpx.gyp:libvpx',
'<(libvpx_dir)/libvpx.gyp:libvpx',
],
}],
],
['build_vp9==1', {
'sources': [
'include/vp9.h',
'vp9_impl.cc',
'vp9_impl.h',
],
}, {
'sources': [
'vp9_dummy_impl.cc',
],
}],
],
},
],
}

View File

@ -0,0 +1,19 @@
/*
* Copyright (c) 2015 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.
*
*/
// This file contains an implementation of empty webrtc VP9 encoder/decoder
// factories so it is possible to build webrtc without linking with vp9.
#include "webrtc/modules/video_coding/codecs/vp9/vp9_impl.h"
namespace webrtc {
VP9Encoder* VP9Encoder::Create() { return nullptr; }
VP9Decoder* VP9Decoder::Create() { return nullptr; }
}

View File

@ -115,6 +115,11 @@
}, {
'sources!': [ 'source/data_log.cc', ],
},],
['rtc_use_direct_trace==1', {
'defines': [
'WEBRTC_DIRECT_TRACE',
],
}],
['OS=="android"', {
'defines': [
'WEBRTC_THREAD_RR',