Make some build settings more flexible.

BUG=issue676
TEST=trybots

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

git-svn-id: http://webrtc.googlecode.com/svn/trunk@2524 4adac7df-926f-26a2-2b94-8c16560cd09d
This commit is contained in:
andrew@webrtc.org 2012-07-23 16:28:02 +00:00
parent a9da4c55ef
commit f5a91fdfab
11 changed files with 76 additions and 83 deletions

View File

@ -13,12 +13,22 @@
# These variables need to be nested in order to use them in a conditions
# block to set other variables.
'variables': {
# This will be set to zero in the supplement.gypi triggered by a gclient
# hook in the standalone build.
'build_with_chromium%': 1,
'variables': {
# This will be set to zero in the supplement.gypi triggered by a gclient
# hook in the standalone build.
'build_with_chromium%': 1,
},
'build_with_chromium%': '<(build_with_chromium)',
'conditions': [
['build_with_chromium==1', {
'webrtc_root%': '<(DEPTH)/third_party/webrtc',
}, {
'webrtc_root%': '<(DEPTH)/src',
}],
],
},
'build_with_chromium%': '<(build_with_chromium)',
'webrtc_root%': '<(webrtc_root)',
# The Chromium common.gypi we use treats all gyp files without
# chromium_code==1 as third party code. This disables many of the
@ -44,6 +54,8 @@
'build_libjpeg%': 1,
'build_libyuv%': 1,
'webrtc_vp8_dir%': '<(webrtc_root)/modules/video_coding/codecs/vp8',
'conditions': [
['OS=="android"', {
# On Android, we always prefer fixed_point to reduce CPU usage.
@ -63,16 +75,14 @@
# Exclude internal video render module in Chromium build.
'include_internal_video_render%': 0,
'include_video_engine_file_api%': 0,
# Disable the use of protocol buffers in production code.
'enable_protobuf%': 0,
# Don't include tests for Chromium builds.
'include_tests%': 0,
'webrtc_root%': '<(DEPTH)/third_party/webrtc',
}, {
# Settings for the standalone (not-in-Chromium) build.
}, { # Settings for the standalone (not-in-Chromium) build.
'include_pulse_audio%': 1,
'include_internal_audio_device%': 1,
@ -81,12 +91,12 @@
'include_internal_video_render%': 1,
'include_video_engine_file_api%': 1,
'enable_protobuf%': 1,
'include_tests%': 1,
'webrtc_root%': '<(DEPTH)/src',
# TODO(andrew): For now, disable the Chrome plugins, which causes a
# flood of chromium-style warnings. Investigate enabling them:
# http://code.google.com/p/webrtc/issues/detail?id=163
@ -96,7 +106,8 @@
},
'target_defaults': {
'include_dirs': [
'..','../..', # common_types.h, typedefs.h
# TODO(andrew): we should be able to just use <(webrtc_root) here.
'..','../..',
],
'defines': [
'WEBRTC_SVNREVISION="<!(python <(webrtc_root)/build/version.py)"',
@ -156,7 +167,7 @@
'msvs_disabled_warnings!': [4189,],
}],
['OS=="android"', {
# On android, we always perfer fixed_point to reduce cpu usage
# On Android, we always prefer fixed_point to reduce CPU usage.
'prefer_fixed_point%': 1,
'defines': [

View File

@ -106,9 +106,8 @@
#define WEBRTC_VIDEO_ENGINE_RTP_RTCP_API
// #define WEBRTC_VIDEO_ENGINE_EXTERNAL_CODEC_API
#ifndef WEBRTC_CHROMIUM_BUILD
#define WEBRTC_VIDEO_ENGINE_FILE_API
#endif
// Now handled by gyp:
// WEBRTC_VIDEO_ENGINE_FILE_API
// ============================================================================
// Platform specific configurations

View File

@ -7,23 +7,32 @@
# be found in the AUTHORS file in the root of the source tree.
{
'variables': {
'audio_coding_dependencies': [
'CNG',
'G711',
'G722',
'iLBC',
'iSAC',
'iSACFix',
'PCM16B',
'NetEq',
'<(webrtc_root)/common_audio/common_audio.gyp:resampler',
'<(webrtc_root)/common_audio/common_audio.gyp:signal_processing',
'<(webrtc_root)/common_audio/common_audio.gyp:vad',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
],
'audio_coding_defines': [],
},
'targets': [
{
'target_name': 'audio_coding_module',
'type': '<(library)',
'defines': [
'<@(audio_coding_defines)',
],
'dependencies': [
'CNG',
'G711',
'G722',
'iLBC',
'iSAC',
'iSACFix',
'PCM16B',
'NetEq',
'<(webrtc_root)/common_audio/common_audio.gyp:resampler',
'<(webrtc_root)/common_audio/common_audio.gyp:signal_processing',
'<(webrtc_root)/common_audio/common_audio.gyp:vad',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<@(audio_coding_dependencies)',
],
'include_dirs': [
'../interface',

View File

@ -32,8 +32,6 @@
'udp_transport/source/udp_transport.gypi',
'utility/source/utility.gypi',
'video_coding/codecs/i420/main/source/i420.gypi',
'video_coding/codecs/test_framework/test_framework.gypi',
'video_coding/codecs/vp8/main/source/vp8.gypi',
'video_coding/main/source/video_coding.gypi',
'video_capture/main/source/video_capture.gypi',
'video_processing/main/source/video_processing.gypi',

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -34,8 +34,8 @@
'dependencies': [
'video_codecs_test_framework',
'webrtc_video_coding',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<(DEPTH)/testing/gmock.gyp:gmock',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<(webrtc_root)/test/test.gyp:test_support_main',
],
'sources': [
@ -50,10 +50,10 @@
'dependencies': [
'video_codecs_test_framework',
'webrtc_video_coding',
'webrtc_vp8',
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(webrtc_root)/test/metrics.gyp:metrics',
'<(webrtc_root)/test/test.gyp:test_support_main',
'<(webrtc_vp8_dir)/main/source/vp8.gyp:webrtc_vp8',
],
'sources': [
'videoprocessor_integrationtest.cc',
@ -63,9 +63,3 @@
}], # include_tests
], # conditions
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -15,11 +15,11 @@
'type': '<(library)',
'dependencies': [
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(webrtc_root)/common_video/common_video.gyp:webrtc_libyuv',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<(webrtc_root)/test/metrics.gyp:metrics',
'<(webrtc_root)/test/test.gyp:test_support',
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<(webrtc_root)/common_video/common_video.gyp:webrtc_libyuv',
],
'include_dirs': [
@ -62,9 +62,3 @@
}], # include_tests
], # conditions
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -16,9 +16,9 @@
'dependencies': [
'video_codecs_test_framework',
'webrtc_video_coding',
'webrtc_vp8',
'<(webrtc_root)/test/metrics.gyp:metrics',
'<(DEPTH)/third_party/google-gflags/google-gflags.gyp:google-gflags',
'<(webrtc_root)/test/metrics.gyp:metrics',
'<(webrtc_vp8_dir)/main/source/vp8.gyp:webrtc_vp8',
],
'sources': [
'video_quality_measurement.cc',
@ -28,9 +28,3 @@
}], # include_tests
], # conditions
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -7,6 +7,10 @@
# be found in the AUTHORS file in the root of the source tree.
{
'includes': [
'../../../../../../build/common.gypi',
'../../../test_framework/test_framework.gypi'
],
'targets': [
{
'target_name': 'webrtc_vp8',
@ -91,10 +95,10 @@
'target_name': 'vp8_unittests',
'type': 'executable',
'dependencies': [
'<(webrtc_root)/test/test.gyp:test_support_main',
'webrtc_vp8',
'<(DEPTH)/testing/gtest.gyp:gtest',
'<(DEPTH)/third_party/libvpx/libvpx.gyp:libvpx',
'webrtc_vp8',
'<(webrtc_root)/test/test.gyp:test_support_main',
],
'include_dirs': [
'<(DEPTH)/third_party/libvpx/source/libvpx',
@ -108,9 +112,3 @@
}], # include_tests
],
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -13,9 +13,9 @@
'type': '<(library)',
'dependencies': [
'webrtc_i420',
'webrtc_vp8',
'<(webrtc_root)/common_video/common_video.gyp:webrtc_libyuv',
'<(webrtc_root)/system_wrappers/source/system_wrappers.gyp:system_wrappers',
'<(webrtc_vp8_dir)/main/source/vp8.gyp:webrtc_vp8',
],
'include_dirs': [
'../interface',
@ -98,9 +98,3 @@
},
],
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -7,6 +7,13 @@
# be found in the AUTHORS file in the root of the source tree.
{
'target_defaults': {
'conditions': [
['include_video_engine_file_api==1', {
'defines': [ 'WEBRTC_VIDEO_ENGINE_FILE_API', ],
}],
],
},
'targets': [
{
'target_name': 'video_engine_core',
@ -158,9 +165,3 @@
}], # include_tests
], # conditions
}
# Local Variables:
# tab-width:2
# indent-tabs-mode:nil
# End:
# vim: set expandtab tabstop=2 shiftwidth=2:

View File

@ -1,4 +1,4 @@
# Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
# Copyright (c) 2012 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
@ -22,6 +22,7 @@
'src/test/metrics.gyp:*',
'src/test/test.gyp:*',
'tools/e2e_quality/e2e_quality.gyp:*',
'<(webrtc_vp8_dir)/main/source/vp8.gyp:*'
],
},
],