diff options
author | kjellander@webrtc.org <kjellander@webrtc.org> | 2015-01-20 11:40:45 +0000 |
---|---|---|
committer | kjellander@webrtc.org <kjellander@webrtc.org> | 2015-01-20 11:40:45 +0000 |
commit | 853049fa308c3181769e8ee13eddb289d573a065 (patch) | |
tree | cd5caf5f3c58859359be0632b515b9c9a1d3d87d | |
parent | 511ab3e7c8ac887e8b270f461d21add49abd060a (diff) | |
download | webrtc-853049fa308c3181769e8ee13eddb289d573a065.tar.gz |
Move internal capture+render to build_with_chromium==0 condition
This will avoid errors related to DirectX not being found
for Chromium bots (mainly GN, but it's safest to do the same
changes for GYP since they also make sense there as GYP generation
go slightly faster without having to process those targets).
Thanks to vchigrin@yandex-team.ru for originally suggesting
this being fixed in
https://webrtc-codereview.appspot.com/37639004/
TESTED=
Successfully ran:
webrtc/build/gyp_webrtc
webrtc/build/gyp_webrtc -Dbuild_with_chromium=1
and trybots.
R=andresp@webrtc.org
Review URL: https://webrtc-codereview.appspot.com/38619004
git-svn-id: http://webrtc.googlecode.com/svn/trunk@8102 4adac7df-926f-26a2-2b94-8c16560cd09d
-rwxr-xr-x | talk/libjingle.gyp | 12 | ||||
-rw-r--r-- | webrtc/modules/video_capture/BUILD.gn | 211 | ||||
-rw-r--r-- | webrtc/modules/video_capture/video_capture.gypi | 210 | ||||
-rw-r--r-- | webrtc/modules/video_render/BUILD.gn | 212 | ||||
-rw-r--r-- | webrtc/modules/video_render/video_render.gypi | 210 | ||||
-rw-r--r-- | webrtc/webrtc_examples.gyp | 2 |
6 files changed, 431 insertions, 426 deletions
diff --git a/talk/libjingle.gyp b/talk/libjingle.gyp index ee03bd0bd4..81e38e179c 100755 --- a/talk/libjingle.gyp +++ b/talk/libjingle.gyp @@ -461,16 +461,16 @@ ], 'conditions': [ ['build_with_chromium==1', { - 'dependencies': [ + 'dependencies': [ '<(webrtc_root)/modules/modules.gyp:video_capture_module_impl', '<(webrtc_root)/modules/modules.gyp:video_render_module_impl', - ], - }, { - 'dependencies': [ + ], + }, { + 'dependencies': [ '<(webrtc_root)/modules/modules.gyp:video_capture_module_internal_impl', '<(webrtc_root)/modules/modules.gyp:video_render_module_internal_impl', - ], - }], + ], + }], ['OS=="linux"', { 'sources': [ 'media/devices/gtkvideorenderer.cc', diff --git a/webrtc/modules/video_capture/BUILD.gn b/webrtc/modules/video_capture/BUILD.gn index 48b8fc0969..bcc104ccda 100644 --- a/webrtc/modules/video_capture/BUILD.gn +++ b/webrtc/modules/video_capture/BUILD.gn @@ -63,115 +63,114 @@ source_set("video_capture_impl") { } } -config("video_capture_internal_impl_config") { - if (is_ios) { - libs = [ - "AVFoundation.framework", - "CoreMedia.framework", - "CoreVideo.framework", - ] - } -} - -source_set("video_capture_internal_impl") { - deps = [ - ":video_capture", - "../../system_wrappers", - ] - - if (is_linux) { - sources = [ - "linux/device_info_linux.cc", - "linux/device_info_linux.h", - "linux/video_capture_linux.cc", - "linux/video_capture_linux.h", - ] - } - if (is_mac) { - sources = [ - "mac/qtkit/video_capture_qtkit.h", - "mac/qtkit/video_capture_qtkit.mm", - "mac/qtkit/video_capture_qtkit_info.h", - "mac/qtkit/video_capture_qtkit_info.mm", - "mac/qtkit/video_capture_qtkit_info_objc.h", - "mac/qtkit/video_capture_qtkit_info_objc.mm", - "mac/qtkit/video_capture_qtkit_objc.h", - "mac/qtkit/video_capture_qtkit_objc.mm", - "mac/qtkit/video_capture_qtkit_utility.h", - "mac/video_capture_mac.mm", - ] - - libs = [ - "CoreVideo.framework", - "QTKit.framework", - ] - } - # winsdk_samples isn't pulled into Chromium, so it is disabled for Chromium - # builds. This is not a problem since the internal video capture - # implementation should not be used in chrome - issue 3831. - if (is_win && !build_with_chromium) { - sources = [ - "windows/device_info_ds.cc", - "windows/device_info_ds.h", - "windows/device_info_mf.cc", - "windows/device_info_mf.h", - "windows/help_functions_ds.cc", - "windows/help_functions_ds.h", - "windows/sink_filter_ds.cc", - "windows/sink_filter_ds.h", - "windows/video_capture_ds.cc", - "windows/video_capture_ds.h", - "windows/video_capture_factory_windows.cc", - "windows/video_capture_mf.cc", - "windows/video_capture_mf.h", - ] - - libs = [ "Strmiids.lib" ] - - deps += [ "//third_party/winsdk_samples"] - } - if (is_android) { - sources = [ - "android/device_info_android.cc", - "android/device_info_android.h", - "android/video_capture_android.cc", - "android/video_capture_android.h", - ] - - deps += [ - "//third_party/icu:icuuc", - "//third_party/jsoncpp", - ] +if (!build_with_chromium) { + config("video_capture_internal_impl_config") { + if (is_ios) { + libs = [ + "AVFoundation.framework", + "CoreMedia.framework", + "CoreVideo.framework", + ] + } } - if (is_ios) { - sources = [ - "ios/device_info_ios.h", - "ios/device_info_ios.mm", - "ios/device_info_ios_objc.h", - "ios/device_info_ios_objc.mm", - "ios/rtc_video_capture_ios_objc.h", - "ios/rtc_video_capture_ios_objc.mm", - "ios/video_capture_ios.h", - "ios/video_capture_ios.mm", - ] - cflags = [ - "-fobjc-arc", # CLANG_ENABLE_OBJC_ARC = YES. - # To avoid warnings for deprecated videoMinFrameDuration and - # videoMaxFrameDuration properties in iOS 7.0. - # See webrtc:3705 for more details. - "-Wno-deprecated-declarations", + source_set("video_capture_internal_impl") { + deps = [ + ":video_capture", + "../../system_wrappers", ] - } - all_dependent_configs = [ ":video_capture_internal_impl_config" ] - - configs += [ "../..:common_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:find_bad_constructs" ] + if (is_linux) { + sources = [ + "linux/device_info_linux.cc", + "linux/device_info_linux.h", + "linux/video_capture_linux.cc", + "linux/video_capture_linux.h", + ] + } + if (is_mac) { + sources = [ + "mac/qtkit/video_capture_qtkit.h", + "mac/qtkit/video_capture_qtkit.mm", + "mac/qtkit/video_capture_qtkit_info.h", + "mac/qtkit/video_capture_qtkit_info.mm", + "mac/qtkit/video_capture_qtkit_info_objc.h", + "mac/qtkit/video_capture_qtkit_info_objc.mm", + "mac/qtkit/video_capture_qtkit_objc.h", + "mac/qtkit/video_capture_qtkit_objc.mm", + "mac/qtkit/video_capture_qtkit_utility.h", + "mac/video_capture_mac.mm", + ] + + libs = [ + "CoreVideo.framework", + "QTKit.framework", + ] + } + if (is_win) { + sources = [ + "windows/device_info_ds.cc", + "windows/device_info_ds.h", + "windows/device_info_mf.cc", + "windows/device_info_mf.h", + "windows/help_functions_ds.cc", + "windows/help_functions_ds.h", + "windows/sink_filter_ds.cc", + "windows/sink_filter_ds.h", + "windows/video_capture_ds.cc", + "windows/video_capture_ds.h", + "windows/video_capture_factory_windows.cc", + "windows/video_capture_mf.cc", + "windows/video_capture_mf.h", + ] + + libs = [ "Strmiids.lib" ] + + deps += [ "//third_party/winsdk_samples"] + } + if (is_android) { + sources = [ + "android/device_info_android.cc", + "android/device_info_android.h", + "android/video_capture_android.cc", + "android/video_capture_android.h", + ] + + deps += [ + "//third_party/icu:icuuc", + "//third_party/jsoncpp", + ] + } + if (is_ios) { + sources = [ + "ios/device_info_ios.h", + "ios/device_info_ios.mm", + "ios/device_info_ios_objc.h", + "ios/device_info_ios_objc.mm", + "ios/rtc_video_capture_ios_objc.h", + "ios/rtc_video_capture_ios_objc.mm", + "ios/video_capture_ios.h", + "ios/video_capture_ios.mm", + ] + + cflags = [ + "-fobjc-arc", # CLANG_ENABLE_OBJC_ARC = YES. + # To avoid warnings for deprecated videoMinFrameDuration and + # videoMaxFrameDuration properties in iOS 7.0. + # See webrtc:3705 for more details. + "-Wno-deprecated-declarations", + ] + } + + all_dependent_configs = [ ":video_capture_internal_impl_config" ] + + configs += [ "../..:common_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:find_bad_constructs" ] + } } } diff --git a/webrtc/modules/video_capture/video_capture.gypi b/webrtc/modules/video_capture/video_capture.gypi index 771c147b60..4d43c17bd3 100644 --- a/webrtc/modules/video_capture/video_capture.gypi +++ b/webrtc/modules/video_capture/video_capture.gypi @@ -46,114 +46,114 @@ 'external/video_capture_external.cc', ], }, - { - 'target_name': 'video_capture_module_internal_impl', - 'type': 'static_library', - 'dependencies': [ - 'video_capture_module', - ], - 'conditions': [ - ['OS=="linux"', { - 'sources': [ - 'linux/device_info_linux.cc', - 'linux/device_info_linux.h', - 'linux/video_capture_linux.cc', - 'linux/video_capture_linux.h', - ], - }], # linux - ['OS=="mac"', { - 'sources': [ - 'mac/qtkit/video_capture_qtkit.h', - 'mac/qtkit/video_capture_qtkit.mm', - 'mac/qtkit/video_capture_qtkit_info.h', - 'mac/qtkit/video_capture_qtkit_info.mm', - 'mac/qtkit/video_capture_qtkit_info_objc.h', - 'mac/qtkit/video_capture_qtkit_info_objc.mm', - 'mac/qtkit/video_capture_qtkit_objc.h', - 'mac/qtkit/video_capture_qtkit_objc.mm', - 'mac/qtkit/video_capture_qtkit_utility.h', - 'mac/video_capture_mac.mm', - ], - 'link_settings': { - 'xcode_settings': { - 'OTHER_LDFLAGS': [ - '-framework Cocoa', - '-framework CoreVideo', - '-framework QTKit', - ], - }, - }, - }], # mac - # Note that since winsdk_samples isn't pulled into chromium gyp will - # fail to parse this rule and try to resolve the dependencies. This - # is not a problem since the internal video capture implementation - # should not be used in chrome - issue 3831. - ['OS=="win" and build_with_chromium==0', { - 'dependencies': [ - '<(DEPTH)/third_party/winsdk_samples/winsdk_samples.gyp:directshow_baseclasses', - ], - 'sources': [ - 'windows/device_info_ds.cc', - 'windows/device_info_ds.h', - 'windows/device_info_mf.cc', - 'windows/device_info_mf.h', - 'windows/help_functions_ds.cc', - 'windows/help_functions_ds.h', - 'windows/sink_filter_ds.cc', - 'windows/sink_filter_ds.h', - 'windows/video_capture_ds.cc', - 'windows/video_capture_ds.h', - 'windows/video_capture_factory_windows.cc', - 'windows/video_capture_mf.cc', - 'windows/video_capture_mf.h', - ], - 'link_settings': { - 'libraries': [ - '-lStrmiids.lib', - ], - }, - }], # win - ['OS=="android"', { + ], # targets + 'conditions': [ + ['build_with_chromium==0', { + 'targets': [ + { + 'target_name': 'video_capture_module_internal_impl', + 'type': 'static_library', 'dependencies': [ - '<(DEPTH)/third_party/icu/icu.gyp:icuuc', - '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', - ], - 'sources': [ - 'android/device_info_android.cc', - 'android/device_info_android.h', - 'android/video_capture_android.cc', - 'android/video_capture_android.h', - ], - }], # android - ['OS=="ios"', { - 'sources': [ - 'ios/device_info_ios.h', - 'ios/device_info_ios.mm', - 'ios/device_info_ios_objc.h', - 'ios/device_info_ios_objc.mm', - 'ios/rtc_video_capture_ios_objc.h', - 'ios/rtc_video_capture_ios_objc.mm', - 'ios/video_capture_ios.h', - 'ios/video_capture_ios.mm', + 'video_capture_module', ], - 'xcode_settings': { - 'CLANG_ENABLE_OBJC_ARC': 'YES', - }, - 'all_dependent_settings': { - 'xcode_settings': { - 'OTHER_LDFLAGS': [ - '-framework AVFoundation', - '-framework CoreMedia', - '-framework CoreVideo', - '-framework UIKit', + 'conditions': [ + ['OS=="linux"', { + 'sources': [ + 'linux/device_info_linux.cc', + 'linux/device_info_linux.h', + 'linux/video_capture_linux.cc', + 'linux/video_capture_linux.h', ], - }, - }, - }], # ios - ], # conditions - } - ], - 'conditions': [ + }], # linux + ['OS=="mac"', { + 'sources': [ + 'mac/qtkit/video_capture_qtkit.h', + 'mac/qtkit/video_capture_qtkit.mm', + 'mac/qtkit/video_capture_qtkit_info.h', + 'mac/qtkit/video_capture_qtkit_info.mm', + 'mac/qtkit/video_capture_qtkit_info_objc.h', + 'mac/qtkit/video_capture_qtkit_info_objc.mm', + 'mac/qtkit/video_capture_qtkit_objc.h', + 'mac/qtkit/video_capture_qtkit_objc.mm', + 'mac/qtkit/video_capture_qtkit_utility.h', + 'mac/video_capture_mac.mm', + ], + 'link_settings': { + 'xcode_settings': { + 'OTHER_LDFLAGS': [ + '-framework Cocoa', + '-framework CoreVideo', + '-framework QTKit', + ], + }, + }, + }], # mac + ['OS=="win"', { + 'dependencies': [ + '<(DEPTH)/third_party/winsdk_samples/winsdk_samples.gyp:directshow_baseclasses', + ], + 'sources': [ + 'windows/device_info_ds.cc', + 'windows/device_info_ds.h', + 'windows/device_info_mf.cc', + 'windows/device_info_mf.h', + 'windows/help_functions_ds.cc', + 'windows/help_functions_ds.h', + 'windows/sink_filter_ds.cc', + 'windows/sink_filter_ds.h', + 'windows/video_capture_ds.cc', + 'windows/video_capture_ds.h', + 'windows/video_capture_factory_windows.cc', + 'windows/video_capture_mf.cc', + 'windows/video_capture_mf.h', + ], + 'link_settings': { + 'libraries': [ + '-lStrmiids.lib', + ], + }, + }], # win + ['OS=="android"', { + 'dependencies': [ + '<(DEPTH)/third_party/icu/icu.gyp:icuuc', + '<(DEPTH)/third_party/jsoncpp/jsoncpp.gyp:jsoncpp', + ], + 'sources': [ + 'android/device_info_android.cc', + 'android/device_info_android.h', + 'android/video_capture_android.cc', + 'android/video_capture_android.h', + ], + }], # android + ['OS=="ios"', { + 'sources': [ + 'ios/device_info_ios.h', + 'ios/device_info_ios.mm', + 'ios/device_info_ios_objc.h', + 'ios/device_info_ios_objc.mm', + 'ios/rtc_video_capture_ios_objc.h', + 'ios/rtc_video_capture_ios_objc.mm', + 'ios/video_capture_ios.h', + 'ios/video_capture_ios.mm', + ], + 'xcode_settings': { + 'CLANG_ENABLE_OBJC_ARC': 'YES', + }, + 'all_dependent_settings': { + 'xcode_settings': { + 'OTHER_LDFLAGS': [ + '-framework AVFoundation', + '-framework CoreMedia', + '-framework CoreVideo', + '-framework UIKit', + ], + }, + }, + }], # ios + ], # conditions + }, + ], + }], # build_with_chromium==0 ['include_tests==1', { 'targets': [ { diff --git a/webrtc/modules/video_render/BUILD.gn b/webrtc/modules/video_render/BUILD.gn index 9d199f4a25..c5e3091596 100644 --- a/webrtc/modules/video_render/BUILD.gn +++ b/webrtc/modules/video_render/BUILD.gn @@ -57,119 +57,121 @@ source_set("video_render_impl") { } } -config("video_render_internal_impl_config") { - if (is_ios) { - libs = [ - "OpenGLES.framework", - "QuartzCore.framework", - ] - } -} - -source_set("video_render_internal_impl") { - libs = [] - sources = [ - "video_render_internal_impl.cc", - ] - deps = [ - ":video_render", - "../../system_wrappers", - ] - - if (is_linux) { - sources += [ - "linux/video_render_linux_impl.cc", - "linux/video_render_linux_impl.h", - "linux/video_x11_channel.cc", - "linux/video_x11_channel.h", - "linux/video_x11_render.cc", - "linux/video_x11_render.h", - ] - - libs += [ "Xext" ] +if (!build_with_chromium) { + config("video_render_internal_impl_config") { + if (is_ios) { + libs = [ + "OpenGLES.framework", + "QuartzCore.framework", + ] + } } - if (is_mac) { - sources += [ - "mac/cocoa_full_screen_window.h", - "mac/cocoa_full_screen_window.mm", - "mac/cocoa_render_view.h", - "mac/cocoa_render_view.mm", - "mac/video_render_agl.cc", - "mac/video_render_agl.h", - "mac/video_render_mac_carbon_impl.cc", - "mac/video_render_mac_carbon_impl.h", - "mac/video_render_mac_cocoa_impl.h", - "mac/video_render_mac_cocoa_impl.mm", - "mac/video_render_nsopengl.h", - "mac/video_render_nsopengl.mm", - ] - libs += [ - "CoreVideo.framework", - "QTKit.framework", + source_set("video_render_internal_impl") { + libs = [] + sources = [ + "video_render_internal_impl.cc", ] - } - if (is_win) { - sources += [ - "windows/i_video_render_win.h", - "windows/video_render_direct3d9.cc", - "windows/video_render_direct3d9.h", - "windows/video_render_windows_impl.cc", - "windows/video_render_windows_impl.h", + deps = [ + ":video_render", + "../../system_wrappers", ] - directxsdk_exists = - (exec_script("//build/dir_exists.py", - [ rebase_path("//third_party/directxsdk/files", - root_build_dir) ], - "trim string") == "True") - if (directxsdk_exists) { - directxsdk_path = "//third_party/directxsdk/files" - } else { - directxsdk_path = - exec_script("../../build/find_directx_sdk.py", [], "trim string") + if (is_linux) { + sources += [ + "linux/video_render_linux_impl.cc", + "linux/video_render_linux_impl.h", + "linux/video_x11_channel.cc", + "linux/video_x11_channel.h", + "linux/video_x11_render.cc", + "linux/video_x11_render.h", + ] + + libs += [ "Xext" ] + } + if (is_mac) { + sources += [ + "mac/cocoa_full_screen_window.h", + "mac/cocoa_full_screen_window.mm", + "mac/cocoa_render_view.h", + "mac/cocoa_render_view.mm", + "mac/video_render_agl.cc", + "mac/video_render_agl.h", + "mac/video_render_mac_carbon_impl.cc", + "mac/video_render_mac_carbon_impl.h", + "mac/video_render_mac_cocoa_impl.h", + "mac/video_render_mac_cocoa_impl.mm", + "mac/video_render_nsopengl.h", + "mac/video_render_nsopengl.mm", + ] + + libs += [ + "CoreVideo.framework", + "QTKit.framework", + ] + } + if (is_win) { + sources += [ + "windows/i_video_render_win.h", + "windows/video_render_direct3d9.cc", + "windows/video_render_direct3d9.h", + "windows/video_render_windows_impl.cc", + "windows/video_render_windows_impl.h", + ] + + directxsdk_exists = + (exec_script("//build/dir_exists.py", + [ rebase_path("//third_party/directxsdk/files", + root_build_dir) ], + "trim string") == "True") + if (directxsdk_exists) { + directxsdk_path = "//third_party/directxsdk/files" + } else { + directxsdk_path = + exec_script("../../build/find_directx_sdk.py", [], "trim string") + } + include_dirs = [ directxsdk_path + "/Include" ] + } + if (is_android) { + sources += [ + "android/video_render_android_impl.cc", + "android/video_render_android_impl.h", + "android/video_render_android_native_opengl2.cc", + "android/video_render_android_native_opengl2.h", + "android/video_render_android_surface_view.cc", + "android/video_render_android_surface_view.h", + "android/video_render_opengles20.cc", + "android/video_render_opengles20.h", + ] + + libs += [ "GLESv2" ] + } + if (is_ios) { + sources += [ + "ios/open_gles20.h", + "ios/open_gles20.mm", + "ios/video_render_ios_channel.h", + "ios/video_render_ios_channel.mm", + "ios/video_render_ios_gles20.h", + "ios/video_render_ios_gles20.mm", + "ios/video_render_ios_impl.h", + "ios/video_render_ios_impl.mm", + "ios/video_render_ios_view.h", + "ios/video_render_ios_view.mm", + ] + + cflags += [ "-fobjc-arc" ] # CLANG_ENABLE_OBJC_ARC = YES. } - include_dirs = [ directxsdk_path + "/Include" ] - } - if (is_android) { - sources += [ - "android/video_render_android_impl.cc", - "android/video_render_android_impl.h", - "android/video_render_android_native_opengl2.cc", - "android/video_render_android_native_opengl2.h", - "android/video_render_android_surface_view.cc", - "android/video_render_android_surface_view.h", - "android/video_render_opengles20.cc", - "android/video_render_opengles20.h", - ] - - libs += [ "GLESv2" ] - } - if (is_ios) { - sources += [ - "ios/open_gles20.h", - "ios/open_gles20.mm", - "ios/video_render_ios_channel.h", - "ios/video_render_ios_channel.mm", - "ios/video_render_ios_gles20.h", - "ios/video_render_ios_gles20.mm", - "ios/video_render_ios_impl.h", - "ios/video_render_ios_impl.mm", - "ios/video_render_ios_view.h", - "ios/video_render_ios_view.mm", - ] - - cflags += [ "-fobjc-arc" ] # CLANG_ENABLE_OBJC_ARC = YES. - } - all_dependent_configs = [ ":video_render_internal_impl_config"] + all_dependent_configs = [ ":video_render_internal_impl_config"] - configs += [ "../..:common_config" ] - public_configs = [ "../..:common_inherited_config" ] + configs += [ "../..:common_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:find_bad_constructs" ] + 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:find_bad_constructs" ] + } } } diff --git a/webrtc/modules/video_render/video_render.gypi b/webrtc/modules/video_render/video_render.gypi index 3540b6a01f..59ce9f764a 100644 --- a/webrtc/modules/video_render/video_render.gypi +++ b/webrtc/modules/video_render/video_render.gypi @@ -45,112 +45,116 @@ 'video_render_impl.cc', ], }, - { - # video_render_module implementation that supports the internal - # video_render implementation. - 'target_name': 'video_render_module_internal_impl', - 'type': 'static_library', - 'dependencies': [ - 'video_render_module', - ], - 'sources': [ - 'video_render_internal_impl.cc', - ], - # TODO(andrew): with the proper suffix, these files will be excluded - # automatically. - 'conditions': [ - ['OS=="android"', { - 'sources': [ - 'android/video_render_android_impl.h', - 'android/video_render_android_native_opengl2.h', - 'android/video_render_android_surface_view.h', - 'android/video_render_opengles20.h', - 'android/video_render_android_impl.cc', - 'android/video_render_android_native_opengl2.cc', - 'android/video_render_android_surface_view.cc', - 'android/video_render_opengles20.cc', + ], # targets + + 'conditions': [ + ['build_with_chromium==0', { + 'targets': [ + { + # video_render_module implementation that supports the internal + # video_render implementation. + 'target_name': 'video_render_module_internal_impl', + 'type': 'static_library', + 'dependencies': [ + 'video_render_module', ], - 'link_settings': { - 'libraries': [ - '-lGLESv2', - ], - }, - }], - ['OS=="ios"', { 'sources': [ - # iOS - 'ios/open_gles20.h', - 'ios/open_gles20.mm', - 'ios/video_render_ios_channel.h', - 'ios/video_render_ios_channel.mm', - 'ios/video_render_ios_gles20.h', - 'ios/video_render_ios_gles20.mm', - 'ios/video_render_ios_impl.h', - 'ios/video_render_ios_impl.mm', - 'ios/video_render_ios_view.h', - 'ios/video_render_ios_view.mm', + 'video_render_internal_impl.cc', ], - 'xcode_settings': { - 'CLANG_ENABLE_OBJC_ARC': 'YES', - }, - 'all_dependent_settings': { - 'xcode_settings': { - 'OTHER_LDFLAGS': [ - '-framework OpenGLES', - '-framework QuartzCore', - '-framework UIKit', + # TODO(andrew): with the proper suffix, these files will be excluded + # automatically. + 'conditions': [ + ['OS=="android"', { + 'sources': [ + 'android/video_render_android_impl.h', + 'android/video_render_android_native_opengl2.h', + 'android/video_render_android_surface_view.h', + 'android/video_render_opengles20.h', + 'android/video_render_android_impl.cc', + 'android/video_render_android_native_opengl2.cc', + 'android/video_render_android_surface_view.cc', + 'android/video_render_opengles20.cc', ], - }, - }, - }], - ['OS=="linux"', { - 'sources': [ - 'linux/video_render_linux_impl.h', - 'linux/video_x11_channel.h', - 'linux/video_x11_render.h', - 'linux/video_render_linux_impl.cc', - 'linux/video_x11_channel.cc', - 'linux/video_x11_render.cc', - ], - 'link_settings': { - 'libraries': [ - '-lXext', - ], - }, - }], - ['OS=="mac"', { - 'sources': [ - 'mac/cocoa_full_screen_window.h', - 'mac/cocoa_render_view.h', - 'mac/video_render_agl.h', - 'mac/video_render_mac_carbon_impl.h', - 'mac/video_render_mac_cocoa_impl.h', - 'mac/video_render_nsopengl.h', - 'mac/video_render_nsopengl.mm', - 'mac/video_render_mac_cocoa_impl.mm', - 'mac/video_render_agl.cc', - 'mac/video_render_mac_carbon_impl.cc', - 'mac/cocoa_render_view.mm', - 'mac/cocoa_full_screen_window.mm', - ], - }], - ['OS=="win"', { - 'sources': [ - 'windows/i_video_render_win.h', - 'windows/video_render_direct3d9.h', - 'windows/video_render_windows_impl.h', - 'windows/video_render_direct3d9.cc', - 'windows/video_render_windows_impl.cc', - ], - 'include_dirs': [ - '<(directx_sdk_path)/Include', - ], - }], - ] # conditions - }, - ], # targets - - 'conditions': [ + 'link_settings': { + 'libraries': [ + '-lGLESv2', + ], + }, + }], + ['OS=="ios"', { + 'sources': [ + # iOS + 'ios/open_gles20.h', + 'ios/open_gles20.mm', + 'ios/video_render_ios_channel.h', + 'ios/video_render_ios_channel.mm', + 'ios/video_render_ios_gles20.h', + 'ios/video_render_ios_gles20.mm', + 'ios/video_render_ios_impl.h', + 'ios/video_render_ios_impl.mm', + 'ios/video_render_ios_view.h', + 'ios/video_render_ios_view.mm', + ], + 'xcode_settings': { + 'CLANG_ENABLE_OBJC_ARC': 'YES', + }, + 'all_dependent_settings': { + 'xcode_settings': { + 'OTHER_LDFLAGS': [ + '-framework OpenGLES', + '-framework QuartzCore', + '-framework UIKit', + ], + }, + }, + }], + ['OS=="linux"', { + 'sources': [ + 'linux/video_render_linux_impl.h', + 'linux/video_x11_channel.h', + 'linux/video_x11_render.h', + 'linux/video_render_linux_impl.cc', + 'linux/video_x11_channel.cc', + 'linux/video_x11_render.cc', + ], + 'link_settings': { + 'libraries': [ + '-lXext', + ], + }, + }], + ['OS=="mac"', { + 'sources': [ + 'mac/cocoa_full_screen_window.h', + 'mac/cocoa_render_view.h', + 'mac/video_render_agl.h', + 'mac/video_render_mac_carbon_impl.h', + 'mac/video_render_mac_cocoa_impl.h', + 'mac/video_render_nsopengl.h', + 'mac/video_render_nsopengl.mm', + 'mac/video_render_mac_cocoa_impl.mm', + 'mac/video_render_agl.cc', + 'mac/video_render_mac_carbon_impl.cc', + 'mac/cocoa_render_view.mm', + 'mac/cocoa_full_screen_window.mm', + ], + }], + ['OS=="win"', { + 'sources': [ + 'windows/i_video_render_win.h', + 'windows/video_render_direct3d9.h', + 'windows/video_render_windows_impl.h', + 'windows/video_render_direct3d9.cc', + 'windows/video_render_windows_impl.cc', + ], + 'include_dirs': [ + '<(directx_sdk_path)/Include', + ], + }], + ] # conditions + }, + ], + }], # build_with_chromium==0 ['include_tests==1', { 'targets': [ { @@ -213,7 +217,7 @@ ], }], ], - }], # include_tests==0 + }], # include_tests==1 ], # conditions } diff --git a/webrtc/webrtc_examples.gyp b/webrtc/webrtc_examples.gyp index 03b5df764f..52be45c7ba 100644 --- a/webrtc/webrtc_examples.gyp +++ b/webrtc/webrtc_examples.gyp @@ -17,7 +17,7 @@ 'dependencies': [ '<(DEPTH)/third_party/icu/icu.gyp:icuuc', '<(webrtc_root)/modules/modules.gyp:video_capture_module_internal_impl', - '<(webrtc_root)/modules/modules.gyp:video_render_module_internal_impl', + '<(webrtc_root)/modules/modules.gyp:video_render_module_internal_impl', '<(webrtc_root)/system_wrappers/system_wrappers.gyp:system_wrappers_default', '<(webrtc_root)/test/test.gyp:channel_transport', '<(webrtc_root)/video_engine/video_engine.gyp:video_engine_core', |