summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkjellander@webrtc.org <kjellander@webrtc.org>2014-09-07 17:36:10 +0000
committerkjellander@webrtc.org <kjellander@webrtc.org>2014-09-07 17:36:10 +0000
commit4ad10d659f2e27b129aa510c35a49165ba348a03 (patch)
tree5b3776d28c56b708739dd32e91b1f092dfeb1ab7
parent729d5a92e805a22c51c6cfd928275852e7d17a99 (diff)
downloadwebrtc-4ad10d659f2e27b129aa510c35a49165ba348a03.tar.gz
GN: Prefix WebRTC specific variables with "rtc_"
BUG=3441 TESTED=Trybots + Running GN in a Chromium checkout with src/third_party/webrtc symlinked to the WebRTC checkout with this CL applied, both with the default GN settings and using: --args="os=\"android\" cpu_arch=\"arm\"" R=brettw@chromium.org Review URL: https://webrtc-codereview.appspot.com/27379004 git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@7095 4adac7df-926f-26a2-2b94-8c16560cd09d
-rw-r--r--BUILD.gn10
-rw-r--r--base/BUILD.gn22
-rw-r--r--build/webrtc.gni66
-rw-r--r--common_audio/BUILD.gn4
-rw-r--r--common_video/BUILD.gn2
-rw-r--r--modules/audio_coding/BUILD.gn10
-rw-r--r--modules/audio_device/BUILD.gn4
-rw-r--r--modules/audio_processing/BUILD.gn12
-rw-r--r--modules/utility/BUILD.gn2
-rw-r--r--modules/video_capture/BUILD.gn2
-rw-r--r--modules/video_coding/BUILD.gn2
-rw-r--r--modules/video_render/BUILD.gn2
-rw-r--r--system_wrappers/BUILD.gn2
13 files changed, 70 insertions, 70 deletions
diff --git a/BUILD.gn b/BUILD.gn
index 20290ebb..ce20d868 100644
--- a/BUILD.gn
+++ b/BUILD.gn
@@ -57,13 +57,13 @@ config("common_inherited_config") {
"WEBRTC_LINUX",
"WEBRTC_ANDROID",
]
- if (enable_android_opensl) {
+ if (rtc_enable_android_opensl) {
defines += [ "WEBRTC_ANDROID_OPENSLES" ]
}
}
}
-if (have_dbus_glib) {
+if (rtc_have_dbus_glib) {
pkg_config("dbus-glib") {
packages = [ "dbus-glib-1" ]
}
@@ -72,11 +72,11 @@ if (have_dbus_glib) {
config("common_config") {
cflags = []
cflags_cc = []
- if (restrict_webrtc_logging) {
+ if (rtc_restrict_logging) {
defines = [ "WEBRTC_RESTRICT_LOGGING" ]
}
- if (have_dbus_glib) {
+ if (rtc_have_dbus_glib) {
defines += [ "HAVE_DBUS_GLIB" ]
# TODO(kjellander): Investigate this, it seems like include <dbus/dbus.h>
# is still not found even if the execution of
@@ -85,7 +85,7 @@ config("common_config") {
all_dependent_configs = [ "dbus-glib" ]
}
- if (enable_video) {
+ if (rtc_enable_video) {
defines += [ "WEBRTC_MODULE_UTILITY_VIDEO" ]
}
diff --git a/base/BUILD.gn b/base/BUILD.gn
index b0da45af..4e14ab1c 100644
--- a/base/BUILD.gn
+++ b/base/BUILD.gn
@@ -102,11 +102,11 @@ if (is_linux && !build_with_chromium) {
}
}
-if (build_ssl == 0) {
+if (rtc_build_ssl == 0) {
config("external_ssl_library") {
- assert(webrtc_ssl_root != "",
- "You must specify webrtc_ssl_root when build_ssl==0.")
- include_dirs = [ webrtc_ssl_root ]
+ assert(rtc_ssl_root != "",
+ "You must specify rtc_ssl_root when rtc_build_ssl==0.")
+ include_dirs = [ rtc_ssl_root ]
}
}
@@ -425,10 +425,10 @@ static_library("webrtc_base") {
"win32socketserver.h",
]
}
- if (build_json) {
+ if (rtc_build_json) {
deps += [ "//third_party/jsoncpp" ]
} else {
- include_dirs += [ webrtc_jsoncpp_root ]
+ include_dirs += [ rtc_jsoncpp_root ]
# When defined changes the include path for json.h to where it is
# expected to be when building json outside of the standalone build.
@@ -451,7 +451,7 @@ static_library("webrtc_base") {
if (use_openssl) {
direct_dependent_configs += [ ":openssl_config" ]
- if (build_ssl) {
+ if (rtc_build_ssl) {
deps += [ "//third_party/boringssl" ]
} else {
configs += [ "external_ssl_library" ]
@@ -479,7 +479,7 @@ static_library("webrtc_base") {
if (is_ios) {
all_dependent_configs += [ ":ios_config" ]
- if (build_ssl) {
+ if (rtc_build_ssl) {
deps += [ "//net/third_party/nss/ssl:libssl" ]
} else {
configs += [ "external_ssl_library" ]
@@ -507,7 +507,7 @@ static_library("webrtc_base") {
"dl",
"rt",
]
- if (build_ssl) {
+ if (rtc_build_ssl) {
configs += [ "//third_party/nss:system_nss_no_ssl_config" ]
}
}
@@ -600,7 +600,7 @@ static_library("webrtc_base") {
}
if (is_mac || is_ios || is_win) {
- if (build_ssl) {
+ if (rtc_build_ssl) {
deps += [
"//net/third_party/nss/ssl:libssl",
"//third_party/nss:nspr",
@@ -615,7 +615,7 @@ static_library("webrtc_base") {
if (build_with_chromium) {
deps += [ "//crypto:platform" ]
} else {
- if (build_ssl) {
+ if (rtc_build_ssl) {
deps += [ ":linux_system_ssl" ]
} else {
configs += [ "external_ssl_library" ]
diff --git a/build/webrtc.gni b/build/webrtc.gni
index 346a0622..d46b8c64 100644
--- a/build/webrtc.gni
+++ b/build/webrtc.gni
@@ -15,40 +15,40 @@ declare_args() {
build_with_libjingle = true
# Disable this to avoid building the Opus audio codec.
- include_opus = true
+ rtc_include_opus = true
# Used to specify an external Jsoncpp include path when not compiling the
- # library that comes with WebRTC (i.e. build_json == 0).
- webrtc_jsoncpp_root = "//third_party/jsoncpp/source/include"
+ # library that comes with WebRTC (i.e. rtc_build_json == 0).
+ rtc_jsoncpp_root = "//third_party/jsoncpp/source/include"
# Used to specify an external OpenSSL include path when not compiling the
- # library that comes with WebRTC (i.e. build_ssl == 0).
- webrtc_ssl_root = ""
+ # library that comes with WebRTC (i.e. rtc_build_ssl == 0).
+ rtc_ssl_root = ""
# Adds video support to dependencies shared by voice and video engine.
# This should normally be enabled; the intended use is to disable only
# when building voice engine exclusively.
- enable_video = true
+ rtc_enable_video = true
# Selects fixed-point code where possible.
- prefer_fixed_point = false
+ rtc_prefer_fixed_point = false
# Enable data logging. Produces text files with data logged within engines
# which can be easily parsed for offline processing.
- enable_data_logging = false
+ rtc_enable_data_logging = false
# Enables the use of protocol buffers for debug recordings.
- enable_protobuf = true
+ rtc_enable_protobuf = true
# Disable these to not build components which can be externally provided.
- build_json = true
- build_libjpeg = true
- build_libyuv = true
- build_libvpx = true
- build_ssl = true
+ rtc_build_json = true
+ rtc_build_libjpeg = true
+ rtc_build_libyuv = true
+ rtc_build_libvpx = true
+ rtc_build_ssl = true
# Disable by default.
- have_dbus_glib = false
+ rtc_have_dbus_glib = false
# Enable to use the Mozilla internal settings.
build_with_mozilla = false
@@ -59,26 +59,26 @@ declare_args() {
mips_dsp_rev = 0
mips_fpu = true
- enable_android_opensl = true
+ rtc_enable_android_opensl = true
# Link-Time Optimizations.
# Executes code generation at link-time instead of compile-time.
# https://gcc.gnu.org/wiki/LinkTimeOptimization
- use_lto = false
+ rtc_use_lto = false
if (build_with_chromium) {
# Exclude pulse audio on Chromium since its prerequisites don't require
# pulse audio.
- include_pulse_audio = false
+ rtc_include_pulse_audio = false
# Exclude internal ADM since Chromium uses its own IO handling.
- include_internal_audio_device = false
+ rtc_include_internal_audio_device = false
# Exclude internal VCM in Chromium build.
- include_internal_video_capture = false
+ rtc_include_internal_video_capture = false
# Exclude internal video render module in Chromium build.
- include_internal_video_render = false
+ rtc_include_internal_video_render = false
} else {
# Settings for the standalone (not-in-Chromium) build.
@@ -87,31 +87,31 @@ declare_args() {
# http://code.google.com/p/webrtc/issues/detail?id=163
clang_use_chrome_plugins = false
- include_pulse_audio = true
- include_internal_audio_device = true
- include_internal_video_capture = true
- include_internal_video_render = true
+ rtc_include_pulse_audio = true
+ rtc_include_internal_audio_device = true
+ rtc_include_internal_video_capture = true
+ rtc_include_internal_video_render = true
}
if (build_with_libjingle) {
- include_tests = false
- restrict_webrtc_logging = true
+ rtc_include_tests = false
+ rtc_restrict_logging = true
} else {
- include_tests = true
- restrict_webrtc_logging = false
+ rtc_include_tests = true
+ rtc_restrict_logging = false
}
if (is_ios) {
- build_libjpeg = false
- enable_protobuf = false
+ rtc_build_libjpeg = false
+ rtc_enable_protobuf = false
}
if (cpu_arch == "arm") {
- prefer_fixed_point = true
+ rtc_prefer_fixed_point = true
}
# WebRTC builds ARM v7 Neon instruction set optimized code for both iOS and
# Android, which is why we currently cannot use the variables in
# //build/config/arm.gni (since it disables Neon for Android).
- build_armv7_neon = (cpu_arch == "arm" && arm_version == 7)
+ rtc_build_armv7_neon = (cpu_arch == "arm" && arm_version == 7)
}
diff --git a/common_audio/BUILD.gn b/common_audio/BUILD.gn
index 6b5fe9de..f9bbd6a1 100644
--- a/common_audio/BUILD.gn
+++ b/common_audio/BUILD.gn
@@ -170,7 +170,7 @@ if (cpu_arch == "x86" || cpu_arch == "x64") {
}
}
-if (build_armv7_neon) {
+if (rtc_build_armv7_neon) {
source_set("common_audio_neon") {
sources = [
"fir_filter_neon.cc",
@@ -199,7 +199,7 @@ if (build_armv7_neon) {
]
# Disable LTO in audio_processing_neon target due to compiler bug.
- if (use_lto) {
+ if (rtc_use_lto) {
cflags -= [
"-flto",
"-ffat-lto-objects",
diff --git a/common_video/BUILD.gn b/common_video/BUILD.gn
index d4325432..1b9ad8c7 100644
--- a/common_video/BUILD.gn
+++ b/common_video/BUILD.gn
@@ -42,7 +42,7 @@ source_set("common_video") {
deps = [ "../system_wrappers" ]
- if (build_libyuv) {
+ if (rtc_build_libyuv) {
deps += [ "//third_party/libyuv" ]
} else {
# Need to add a directory normally exported by libyuv.
diff --git a/modules/audio_coding/BUILD.gn b/modules/audio_coding/BUILD.gn
index 6e5a4ef8..8972ff9b 100644
--- a/modules/audio_coding/BUILD.gn
+++ b/modules/audio_coding/BUILD.gn
@@ -102,7 +102,7 @@ source_set("audio_coding") {
"../../system_wrappers",
]
- if (include_opus) {
+ if (rtc_include_opus) {
defines += [ "WEBRTC_CODEC_OPUS" ]
deps += [ ":webrtc_opus" ]
}
@@ -453,7 +453,7 @@ source_set("isacfix") {
"../../system_wrappers",
]
- if (build_armv7_neon) {
+ if (rtc_build_armv7_neon) {
deps += [ ":isac_neon" ]
# Enable compilation for the ARM v7 Neon instruction set. This is needed
@@ -497,7 +497,7 @@ source_set("isacfix") {
}
}
- if (build_armv7_neon) {
+ if (rtc_build_armv7_neon) {
sources += [
"codecs/isac/fix/source/lattice_c.c",
"codecs/isac/fix/source/pitch_estimator_c.c",
@@ -505,7 +505,7 @@ source_set("isacfix") {
}
}
-if (build_armv7_neon) {
+if (rtc_build_armv7_neon) {
source_set("isac_neon") {
sources = [
"codecs/isac/fix/source/entropy_coding_neon.c",
@@ -521,7 +521,7 @@ if (build_armv7_neon) {
]
# Disable LTO in audio_processing_neon target due to compiler bug.
- if (use_lto) {
+ if (rtc_use_lto) {
cflags -= [
"-flto",
"-ffat-lto-objects",
diff --git a/modules/audio_device/BUILD.gn b/modules/audio_device/BUILD.gn
index afc58856..60a83dc3 100644
--- a/modules/audio_device/BUILD.gn
+++ b/modules/audio_device/BUILD.gn
@@ -55,7 +55,7 @@ source_set("audio_device") {
if (is_android) {
include_dirs += [ "android" ]
}
- if (include_internal_audio_device) {
+ if (rtc_include_internal_audio_device) {
sources += [
"linux/alsasymboltable_linux.cc",
"linux/alsasymboltable_linux.h",
@@ -118,7 +118,7 @@ source_set("audio_device") {
"X11",
]
- if (include_pulse_audio) {
+ if (rtc_include_pulse_audio) {
sources += [
"linux/audio_device_pulse_linux.cc",
"linux/audio_device_pulse_linux.h",
diff --git a/modules/audio_processing/BUILD.gn b/modules/audio_processing/BUILD.gn
index 57b721bd..950dfff3 100644
--- a/modules/audio_processing/BUILD.gn
+++ b/modules/audio_processing/BUILD.gn
@@ -89,12 +89,12 @@ source_set("audio_processing") {
defines += [ "WEBRTC_UNTRUSTED_DELAY" ]
}
- if (enable_protobuf) {
+ if (rtc_enable_protobuf) {
defines += [ "WEBRTC_AUDIOPROC_DEBUG_DUMP" ]
deps += [ ":audioproc_debug_proto" ]
}
- if (prefer_fixed_point) {
+ if (rtc_prefer_fixed_point) {
defines += [ "WEBRTC_NS_FIXED" ]
sources += [
"ns/include/noise_suppression_x.h",
@@ -124,7 +124,7 @@ source_set("audio_processing") {
deps += [ ":audio_processing_sse2" ]
}
- if (build_armv7_neon) {
+ if (rtc_build_armv7_neon) {
deps += [ ":audio_processing_neon" ]
}
@@ -159,7 +159,7 @@ source_set("audio_processing") {
]
}
-if (enable_protobuf) {
+if (rtc_enable_protobuf) {
proto_library("audioproc_debug_proto") {
sources = [ "debug.proto" ]
@@ -180,7 +180,7 @@ if (cpu_arch == "x86" || cpu_arch == "x64") {
}
}
-if (build_armv7_neon) {
+if (rtc_build_armv7_neon) {
source_set("audio_processing_neon") {
sources = [
"aec/aec_core_neon.c",
@@ -217,7 +217,7 @@ if (build_armv7_neon) {
]
# Disable LTO in audio_processing_neon target due to compiler bug.
- if (use_lto) {
+ if (rtc_use_lto) {
cflags -= [
"-flto",
"-ffat-lto-objects",
diff --git a/modules/utility/BUILD.gn b/modules/utility/BUILD.gn
index 9856d2da..ff321127 100644
--- a/modules/utility/BUILD.gn
+++ b/modules/utility/BUILD.gn
@@ -42,7 +42,7 @@ source_set("utility") {
"../audio_coding",
"../media_file",
]
- if (enable_video) {
+ if (rtc_enable_video) {
sources += [
"source/frame_scaler.cc",
"source/video_coder.cc",
diff --git a/modules/video_capture/BUILD.gn b/modules/video_capture/BUILD.gn
index 9c314aec..7d6ddc0e 100644
--- a/modules/video_capture/BUILD.gn
+++ b/modules/video_capture/BUILD.gn
@@ -35,7 +35,7 @@ source_set("video_capture") {
libs = []
deps = []
- if (include_internal_video_capture) {
+ if (rtc_include_internal_video_capture) {
if (is_linux) {
sources += [
"linux/device_info_linux.cc",
diff --git a/modules/video_coding/BUILD.gn b/modules/video_coding/BUILD.gn
index 49df4009..42d5d5ce 100644
--- a/modules/video_coding/BUILD.gn
+++ b/modules/video_coding/BUILD.gn
@@ -137,7 +137,7 @@ source_set("webrtc_vp8") {
"../../common_video",
"../../system_wrappers",
]
-# if (build_libvpx) {
+# if (rtc_build_libvpx) {
# deps += [
# "//third_party/libvpx",
# ]
diff --git a/modules/video_render/BUILD.gn b/modules/video_render/BUILD.gn
index fe9259c2..2c14b546 100644
--- a/modules/video_render/BUILD.gn
+++ b/modules/video_render/BUILD.gn
@@ -35,7 +35,7 @@ source_set("video_render") {
libs = []
deps = []
- if (include_internal_video_render) {
+ if (rtc_include_internal_video_render) {
defines += [ "WEBRTC_INCLUDE_INTERNAL_VIDEO_RENDER" ]
if (is_linux) {
diff --git a/system_wrappers/BUILD.gn b/system_wrappers/BUILD.gn
index 5b51e6f1..67c47545 100644
--- a/system_wrappers/BUILD.gn
+++ b/system_wrappers/BUILD.gn
@@ -119,7 +119,7 @@ static_library("system_wrappers") {
":system_wrappers_inherited_config",
]
- if (enable_data_logging) {
+ if (rtc_enable_data_logging) {
sources += [ "source/data_log.cc" ]
} else {
sources += [ "source/data_log_no_op.cc" ]