Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(733)

Unified Diff: webrtc/media/BUILD.gn

Issue 2037983002: Reland of GN: Add BUILD.gn files for webrtc/{api,media,libjingle,p2p,pc} (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: New changes Created 4 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/libjingle/xmpp/BUILD.gn ('k') | webrtc/p2p/BUILD.gn » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/media/BUILD.gn
diff --git a/webrtc/media/BUILD.gn b/webrtc/media/BUILD.gn
new file mode 100644
index 0000000000000000000000000000000000000000..c245d6ee3e67a9412e22b756f1e94c0b9cf83a42
--- /dev/null
+++ b/webrtc/media/BUILD.gn
@@ -0,0 +1,206 @@
+# Copyright (c) 2016 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.
+
+import("//build/config/linux/pkg_config.gni")
+import("../build/webrtc.gni")
+
+group("media") {
+ deps = [
+ ":rtc_media",
+ ]
+}
+
+config("rtc_media_defines_config") {
+ defines = [
+ "HAVE_WEBRTC_VIDEO",
+ "HAVE_WEBRTC_VOICE",
+ ]
+}
+
+config("rtc_media_warnings_config") {
+ # GN orders flags on a target before flags from configs. The default config
+ # adds these flags so to cancel them out they need to come from a config and
+ # cannot be on the target directly.
+ if (!is_win) {
+ cflags = [ "-Wno-deprecated-declarations" ]
+ cflags_cc = [ "-Wno-overloaded-virtual" ]
+ }
+}
+
+if (is_linux && rtc_use_gtk) {
+ pkg_config("gtk-lib") {
+ packages = [
+ "gobject-2.0",
+ "gthread-2.0",
+ "gtk+-2.0",
+ ]
+ }
+}
+
+source_set("rtc_media") {
+ defines = []
+ libs = []
+ deps = []
+ sources = [
+ "base/audiosource.h",
+ "base/codec.cc",
+ "base/codec.h",
+ "base/cpuid.cc",
+ "base/cpuid.h",
+ "base/cryptoparams.h",
+ "base/device.h",
+ "base/fakescreencapturerfactory.h",
+ "base/hybriddataengine.h",
+ "base/mediachannel.h",
+ "base/mediacommon.h",
+ "base/mediaconstants.cc",
+ "base/mediaconstants.h",
+ "base/mediaengine.cc",
+ "base/mediaengine.h",
+ "base/rtpdataengine.cc",
+ "base/rtpdataengine.h",
+ "base/rtpdump.cc",
+ "base/rtpdump.h",
+ "base/rtputils.cc",
+ "base/rtputils.h",
+ "base/screencastid.h",
+ "base/streamparams.cc",
+ "base/streamparams.h",
+ "base/turnutils.cc",
+ "base/turnutils.h",
+ "base/videoadapter.cc",
+ "base/videoadapter.h",
+ "base/videobroadcaster.cc",
+ "base/videobroadcaster.h",
+ "base/videocapturer.cc",
+ "base/videocapturer.h",
+ "base/videocapturerfactory.h",
+ "base/videocommon.cc",
+ "base/videocommon.h",
+ "base/videoframe.cc",
+ "base/videoframe.h",
+ "base/videoframefactory.cc",
+ "base/videoframefactory.h",
+ "base/videorenderer.h",
+ "base/videosourcebase.cc",
+ "base/videosourcebase.h",
+ "base/yuvframegenerator.cc",
+ "base/yuvframegenerator.h",
+ "devices/videorendererfactory.h",
+ "engine/nullwebrtcvideoengine.h",
+ "engine/simulcast.cc",
+ "engine/simulcast.h",
+ "engine/webrtccommon.h",
+ "engine/webrtcmediaengine.cc",
+ "engine/webrtcmediaengine.h",
+ "engine/webrtcvideocapturer.cc",
+ "engine/webrtcvideocapturer.h",
+ "engine/webrtcvideocapturerfactory.cc",
+ "engine/webrtcvideocapturerfactory.h",
+ "engine/webrtcvideodecoderfactory.h",
+ "engine/webrtcvideoencoderfactory.h",
+ "engine/webrtcvideoengine2.cc",
+ "engine/webrtcvideoengine2.h",
+ "engine/webrtcvideoframe.cc",
+ "engine/webrtcvideoframe.h",
+ "engine/webrtcvideoframefactory.cc",
+ "engine/webrtcvideoframefactory.h",
+ "engine/webrtcvoe.h",
+ "engine/webrtcvoiceengine.cc",
+ "engine/webrtcvoiceengine.h",
+ "sctp/sctpdataengine.cc",
+ "sctp/sctpdataengine.h",
+ ]
+
+ configs += [
+ "..:common_config",
+ ":rtc_media_warnings_config",
+ ]
+
+ public_configs = [ "..:common_inherited_config" ]
+
+ if (is_clang) {
+ # Suppress warnings from Chrome's Clang plugins.
+ # See http://code.google.com/p/webrtc/issues/detail?id=163 for details.
+ configs -= [ "//build/config/clang:extra_warnings" ]
+ configs -= [ "//build/config/clang:find_bad_constructs" ]
+ }
+
+ if (is_win) {
+ cflags = [
+ "/wd4245", # conversion from "int" to "size_t", signed/unsigned mismatch.
+ "/wd4267", # conversion from "size_t" to "int", possible loss of data.
+ "/wd4389", # signed/unsigned mismatch.
+ ]
+ }
+
+ if (rtc_build_libyuv) {
+ deps += [ "$rtc_libyuv_dir" ]
+ public_deps = [
+ "$rtc_libyuv_dir",
+ ]
+ } else {
+ # Need to add a directory normally exported by libyuv.
+ include_dirs += [ "$rtc_libyuv_dir/include" ]
+ }
+
+ if (rtc_build_usrsctp) {
+ include_dirs = [
+ # TODO(jiayl): move this into the public_configs of
+ # //third_party/usrsctp/BUILD.gn.
+ "//third_party/usrsctp/usrsctplib",
+ ]
+ deps += [ "//third_party/usrsctp" ]
+ }
+
+ if (build_with_chromium) {
+ deps += [ "../modules/video_capture:video_capture" ]
+ } else {
+ configs += [ ":rtc_media_defines_config" ]
+ public_configs += [ ":rtc_media_defines_config" ]
+ deps += [ "../modules/video_capture:video_capture_internal_impl" ]
+ }
+ if (is_linux && rtc_use_gtk) {
+ sources += [
+ "devices/gtkvideorenderer.cc",
+ "devices/gtkvideorenderer.h",
+ ]
+ public_configs += [ ":gtk-lib" ]
+ }
+ if (is_win) {
+ sources += [
+ "devices/gdivideorenderer.cc",
+ "devices/gdivideorenderer.h",
+ ]
+ libs += [
+ "d3d9.lib",
+ "gdi32.lib",
+ "strmiids.lib",
+ ]
+ }
+ if (is_mac && current_cpu == "x86") {
+ sources += [
+ "devices/carbonvideorenderer.cc",
+ "devices/carbonvideorenderer.h",
+ ]
+ libs += [ "Carbon.framework" ]
+ }
+ if (is_ios || (is_mac && current_cpu != "x86")) {
+ defines += [ "CARBON_DEPRECATED=YES" ]
+ }
+
+ deps += [
+ "..:webrtc_common",
+ "../base:rtc_base_approved",
+ "../libjingle/xmllite",
+ "../libjingle/xmpp",
+ "../p2p",
+ "../system_wrappers",
+ "../voice_engine",
+ ]
+}
« no previous file with comments | « webrtc/libjingle/xmpp/BUILD.gn ('k') | webrtc/p2p/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698