Expand is_linux to is_linux || is_chromeos.

Currently is_linux is set to true on Chrome OS build,
but it is planned to be set false. This CL is the preparation
to keep the compatibility.

Bug: chromium:1110266
Test: Build locally.
Change-Id: Ic79a202b0b3baeff157955cd03a07556bfb958a8
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/183860
Reviewed-by: Mirko Bonadei <mbonadei@webrtc.org>
Commit-Queue: Hidehiko Abe <hidehiko@chromium.org>
Cr-Commit-Position: refs/heads/master@{#32073}
This commit is contained in:
Hidehiko Abe
2020-09-10 18:10:11 +09:00
committed by Commit Bot
parent 0240bcc1f3
commit f264e70a47
11 changed files with 20 additions and 20 deletions

View File

@ -173,7 +173,7 @@ config("common_inherited_config") {
"WEBRTC_IOS", "WEBRTC_IOS",
] ]
} }
if (is_linux) { if (is_linux || is_chromeos) {
defines += [ "WEBRTC_LINUX" ] defines += [ "WEBRTC_LINUX" ]
} }
if (is_mac) { if (is_mac) {

View File

@ -254,7 +254,7 @@ if (rtc_include_tests) {
data += [ "${root_out_dir}/low_bandwidth_audio_test" ] data += [ "${root_out_dir}/low_bandwidth_audio_test" ]
} }
if (is_linux || is_android) { if (is_linux || is_chromeos || is_android) {
data += [ data += [
"../tools_webrtc/audio_quality/linux/PolqaOem64", "../tools_webrtc/audio_quality/linux/PolqaOem64",
"../tools_webrtc/audio_quality/linux/pesq", "../tools_webrtc/audio_quality/linux/pesq",

View File

@ -45,7 +45,7 @@ group("examples") {
deps += [ ":AppRTCMobile" ] deps += [ ":AppRTCMobile" ]
} }
if (is_linux || is_win) { if (is_linux || is_chromeos || is_win) {
deps += [ deps += [
":peerconnection_server", ":peerconnection_server",
":stunserver", ":stunserver",
@ -647,7 +647,7 @@ if (is_ios || (is_mac && target_cpu != "x86")) {
} }
} }
if (is_linux || is_win) { if (is_linux || is_chromeos || is_win) {
rtc_executable("peerconnection_client") { rtc_executable("peerconnection_client") {
testonly = true testonly = true
sources = [ sources = [
@ -691,7 +691,7 @@ if (is_linux || is_win) {
configs += [ "//build/config/win:windowed" ] configs += [ "//build/config/win:windowed" ]
deps += [ "../media:rtc_media_base" ] deps += [ "../media:rtc_media_base" ]
} }
if (is_linux) { if (is_linux || is_chromeos) {
sources += [ sources += [
"peerconnection/client/linux/main.cc", "peerconnection/client/linux/main.cc",
"peerconnection/client/linux/main_wnd.cc", "peerconnection/client/linux/main_wnd.cc",

View File

@ -483,7 +483,7 @@ rtc_library("isac_c") {
"codecs/isac/main/source/transform.c", "codecs/isac/main/source/transform.c",
] ]
if (is_linux) { if (is_linux || is_chromeos) {
libs = [ "m" ] libs = [ "m" ]
} }

View File

@ -263,7 +263,7 @@ rtc_library("audio_device_impl") {
if (rtc_use_dummy_audio_file_devices) { if (rtc_use_dummy_audio_file_devices) {
defines += [ "WEBRTC_DUMMY_FILE_DEVICES" ] defines += [ "WEBRTC_DUMMY_FILE_DEVICES" ]
} else { } else {
if (is_linux) { if (is_linux || is_chromeos) {
sources += [ sources += [
"linux/alsasymboltable_linux.cc", "linux/alsasymboltable_linux.cc",
"linux/alsasymboltable_linux.h", "linux/alsasymboltable_linux.h",
@ -393,7 +393,7 @@ if (rtc_include_tests) {
"../utility", "../utility",
] ]
absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ] absl_deps = [ "//third_party/abseil-cpp/absl/types:optional" ]
if (is_linux || is_mac || is_win) { if (is_linux || is_chromeos || is_mac || is_win) {
sources += [ "audio_device_unittest.cc" ] sources += [ "audio_device_unittest.cc" ]
} }
if (is_win) { if (is_win) {

View File

@ -140,7 +140,7 @@ if (rtc_include_tests) {
"screen_drawer.h", "screen_drawer.h",
] ]
if (is_linux) { if (is_linux || is_chromeos) {
sources += [ "screen_drawer_linux.cc" ] sources += [ "screen_drawer_linux.cc" ]
} }
@ -186,7 +186,7 @@ if (rtc_include_tests) {
} }
} }
if (is_linux) { if (is_linux || is_chromeos) {
if (rtc_use_pipewire) { if (rtc_use_pipewire) {
pkg_config("gio") { pkg_config("gio") {
packages = [ packages = [
@ -357,7 +357,7 @@ rtc_library("desktop_capture_generic") {
"window_capturer_linux.cc", "window_capturer_linux.cc",
] ]
if (build_with_mozilla && is_linux) { if (build_with_mozilla && (is_linux || is_chromeos)) {
sources += [ sources += [
"app_capturer_linux.cc", "app_capturer_linux.cc",
"linux/app_capturer_x11.cc", "linux/app_capturer_x11.cc",

View File

@ -56,7 +56,7 @@ if (!build_with_chromium) {
"../../system_wrappers", "../../system_wrappers",
] ]
if (is_linux) { if (is_linux || is_chromeos) {
sources = [ sources = [
"linux/device_info_linux.cc", "linux/device_info_linux.cc",
"linux/device_info_linux.h", "linux/device_info_linux.h",
@ -113,13 +113,13 @@ if (!build_with_chromium) {
rtc_test("video_capture_tests") { rtc_test("video_capture_tests") {
sources = [ "test/video_capture_unittest.cc" ] sources = [ "test/video_capture_unittest.cc" ]
ldflags = [] ldflags = []
if (is_linux || is_mac) { if (is_linux || is_chromeos || is_mac) {
ldflags += [ ldflags += [
"-lpthread", "-lpthread",
"-lm", "-lm",
] ]
} }
if (is_linux) { if (is_linux || is_chromeos) {
ldflags += [ ldflags += [
"-lrt", "-lrt",
"-lXext", "-lXext",

View File

@ -966,7 +966,7 @@ rtc_library("rtc_base") {
deps += [ "system:cocoa_threading" ] deps += [ "system:cocoa_threading" ]
} }
if (is_linux) { if (is_linux || is_chromeos) {
libs += [ libs += [
"dl", "dl",
"rt", "rt",

View File

@ -57,7 +57,7 @@ rtc_library("system_wrappers") {
libs += [ "log" ] libs += [ "log" ]
} }
if (is_linux) { if (is_linux || is_chromeos) {
if (!build_with_chromium) { if (!build_with_chromium) {
sources += [ "source/cpu_features_linux.cc" ] sources += [ "source/cpu_features_linux.cc" ]
} }

View File

@ -966,17 +966,17 @@ rtc_library("test_renderer_generic") {
] ]
deps += [ "../api:scoped_refptr" ] deps += [ "../api:scoped_refptr" ]
} }
if (!(is_linux && rtc_use_x11) && !is_mac && !is_win) { if (!((is_linux || is_chromeos) && rtc_use_x11) && !is_mac && !is_win) {
sources += [ "null_platform_renderer.cc" ] sources += [ "null_platform_renderer.cc" ]
} }
if ((is_linux && rtc_use_x11) || is_mac) { if (((is_linux || is_chromeos) && rtc_use_x11) || is_mac) {
sources += [ sources += [
"gl/gl_renderer.cc", "gl/gl_renderer.cc",
"gl/gl_renderer.h", "gl/gl_renderer.h",
] ]
} }
if (is_linux && rtc_use_x11) { if ((is_linux || is_chromeos) && rtc_use_x11) {
sources += [ sources += [
"linux/glx_renderer.cc", "linux/glx_renderer.cc",
"linux/glx_renderer.h", "linux/glx_renderer.h",

View File

@ -279,7 +279,7 @@ rtc_opus_dir = "//third_party/opus"
# Desktop capturer is supported only on Windows, OSX and Linux. # Desktop capturer is supported only on Windows, OSX and Linux.
rtc_desktop_capture_supported = rtc_desktop_capture_supported =
(is_win && current_os != "winuwp") || is_mac || (is_win && current_os != "winuwp") || is_mac ||
(is_linux && (rtc_use_x11_extensions || rtc_use_pipewire)) ((is_linux || is_chromeos) && (rtc_use_x11_extensions || rtc_use_pipewire))
############################################################################### ###############################################################################
# Templates # Templates