Source code
Revision control
Copy as Markdown
Other Tools
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
### This moz.build was AUTOMATICALLY GENERATED from a GN config, ###
### DO NOT edit it by hand. ###
if CONFIG["MOZ_WIDGET_TOOLKIT"] == "gtk":
CXXFLAGS += CONFIG["MOZ_GTK3_CFLAGS"]
COMPILE_FLAGS["OS_INCLUDES"] = []
AllowCompilerWarnings()
DEFINES["ABSL_ALLOCATOR_NOTHROW"] = "1"
DEFINES["RTC_DAV1D_IN_INTERNAL_DECODER_FACTORY"] = True
DEFINES["RTC_ENABLE_VP9"] = True
DEFINES["WEBRTC_ENABLE_PROTOBUF"] = "0"
DEFINES["WEBRTC_LIBRARY_IMPL"] = True
DEFINES["WEBRTC_MOZILLA_BUILD"] = True
DEFINES["WEBRTC_NON_STATIC_TRACE_EVENT_HANDLERS"] = "0"
DEFINES["WEBRTC_STRICT_FIELD_TRIALS"] = "0"
FINAL_LIBRARY = "xul"
LOCAL_INCLUDES += [
"!/ipc/ipdl/_ipdlheaders",
"!/third_party/libwebrtc/gen",
"/ipc/chromium/src",
"/media/libyuv/",
"/media/libyuv/libyuv/include/",
"/third_party/abseil-cpp/",
"/third_party/libwebrtc/",
"/tools/profiler/public"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/fallback_desktop_capturer_wrapper.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/blank_detector_desktop_capturer_wrapper.cc",
"/third_party/libwebrtc/modules/desktop_capture/cropped_desktop_frame.cc",
"/third_party/libwebrtc/modules/desktop_capture/cropping_window_capturer.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_and_cursor_composer.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_capture_metrics_helper.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_capture_options.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_capturer.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_capturer_differ_wrapper.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_capturer_wrapper.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_frame_generator.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_frame_rotation.cc",
"/third_party/libwebrtc/modules/desktop_capture/differ_block.cc",
"/third_party/libwebrtc/modules/desktop_capture/fake_desktop_capturer.cc",
"/third_party/libwebrtc/modules/desktop_capture/full_screen_application_handler.cc",
"/third_party/libwebrtc/modules/desktop_capture/full_screen_window_detector.cc",
"/third_party/libwebrtc/modules/desktop_capture/mouse_cursor.cc",
"/third_party/libwebrtc/modules/desktop_capture/resolution_tracker.cc",
"/third_party/libwebrtc/modules/desktop_capture/rgba_color.cc",
"/third_party/libwebrtc/modules/desktop_capture/screen_capturer_helper.cc",
"/third_party/libwebrtc/modules/desktop_capture/window_finder.cc"
]
if not CONFIG["MOZ_DEBUG"]:
DEFINES["DYNAMIC_ANNOTATIONS_ENABLED"] = "0"
DEFINES["NDEBUG"] = True
DEFINES["NVALGRIND"] = True
if CONFIG["MOZ_DEBUG"] == "1":
DEFINES["DYNAMIC_ANNOTATIONS_ENABLED"] = "1"
if CONFIG["OS_TARGET"] == "Darwin":
DEFINES["WEBRTC_MAC"] = True
DEFINES["WEBRTC_POSIX"] = True
DEFINES["_LIBCPP_HAS_NO_ALIGNED_ALLOCATION"] = True
DEFINES["__ASSERT_MACROS_DEFINE_VERSIONS_WITHOUT_UNDERSCORES"] = "0"
DEFINES["__STDC_CONSTANT_MACROS"] = True
DEFINES["__STDC_FORMAT_MACROS"] = True
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/mac/desktop_configuration_monitor.cc",
"/third_party/libwebrtc/modules/desktop_capture/mac/desktop_frame_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/mac/full_screen_mac_application_handler.cc",
"/third_party/libwebrtc/modules/desktop_capture/mac/window_list_utils.cc"
]
if CONFIG["OS_TARGET"] == "Linux":
DEFINES["USE_AURA"] = "1"
DEFINES["USE_GLIB"] = "1"
DEFINES["USE_NSS_CERTS"] = "1"
DEFINES["USE_OZONE"] = "1"
DEFINES["USE_UDEV"] = True
DEFINES["WEBRTC_ENABLE_LIBEVENT"] = True
DEFINES["WEBRTC_LINUX"] = True
DEFINES["WEBRTC_POSIX"] = True
DEFINES["_FILE_OFFSET_BITS"] = "64"
DEFINES["_LARGEFILE64_SOURCE"] = True
DEFINES["_LARGEFILE_SOURCE"] = True
DEFINES["__STDC_CONSTANT_MACROS"] = True
DEFINES["__STDC_FORMAT_MACROS"] = True
OS_LIBS += [
"rt"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/mouse_cursor_monitor_linux.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/screen_capturer_linux.cc",
"/third_party/libwebrtc/modules/desktop_capture/window_capturer_linux.cc"
]
if CONFIG["OS_TARGET"] == "OpenBSD":
DEFINES["USE_GLIB"] = "1"
DEFINES["USE_OZONE"] = "1"
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_BSD"] = True
DEFINES["WEBRTC_ENABLE_LIBEVENT"] = True
DEFINES["WEBRTC_POSIX"] = True
DEFINES["WEBRTC_USE_X11"] = True
DEFINES["_FILE_OFFSET_BITS"] = "64"
DEFINES["_LARGEFILE64_SOURCE"] = True
DEFINES["_LARGEFILE_SOURCE"] = True
DEFINES["__STDC_CONSTANT_MACROS"] = True
DEFINES["__STDC_FORMAT_MACROS"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/mouse_cursor_monitor_linux.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc",
"/third_party/libwebrtc/modules/desktop_capture/screen_capturer_linux.cc",
"/third_party/libwebrtc/modules/desktop_capture/window_capturer_linux.cc"
]
if CONFIG["OS_TARGET"] == "WINNT":
DEFINES["CERT_CHAIN_PARA_HAS_EXTRA_FIELDS"] = True
DEFINES["NOMINMAX"] = True
DEFINES["NTDDI_VERSION"] = "0x0A000000"
DEFINES["PSAPI_VERSION"] = "2"
DEFINES["RTC_ENABLE_WIN_WGC"] = True
DEFINES["UNICODE"] = True
DEFINES["USE_AURA"] = "1"
DEFINES["WEBRTC_WIN"] = True
DEFINES["WIN32"] = True
DEFINES["WIN32_LEAN_AND_MEAN"] = True
DEFINES["WINAPI_FAMILY"] = "WINAPI_FAMILY_DESKTOP_APP"
DEFINES["WINVER"] = "0x0A00"
DEFINES["_ATL_NO_OPENGL"] = True
DEFINES["_CRT_RAND_S"] = True
DEFINES["_CRT_SECURE_NO_DEPRECATE"] = True
DEFINES["_ENABLE_EXTENDED_ALIGNED_STORAGE"] = True
DEFINES["_HAS_EXCEPTIONS"] = "0"
DEFINES["_HAS_NODISCARD"] = True
DEFINES["_SCL_SECURE_NO_DEPRECATE"] = True
DEFINES["_SECURE_ATL"] = True
DEFINES["_UNICODE"] = True
DEFINES["_WIN32_WINNT"] = "0x0A00"
DEFINES["_WINDOWS"] = True
DEFINES["__STD_C"] = True
OS_LIBS += [
"crypt32",
"d3d11",
"dwmapi",
"dxgi",
"iphlpapi",
"secur32",
"shcore",
"winmm"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/win/screen_capturer_win_gdi.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/cropping_window_capturer_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/desktop_frame_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/mouse_cursor_monitor_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/screen_capturer_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/cursor.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/d3d_device.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/desktop.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/desktop_capture_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/display_configuration_monitor.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_adapter_duplicator.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_context.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_duplicator_controller.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_frame.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_output_duplicator.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_texture.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_texture_mapping.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/dxgi_texture_staging.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/full_screen_win_application_handler.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/scoped_thread_desktop.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/screen_capture_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/screen_capturer_win_directx.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/screen_capturer_win_magnifier.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/selected_window_context.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/wgc_capture_session.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/wgc_capture_source.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/wgc_capturer_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/wgc_desktop_frame.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/window_capture_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/win/window_capturer_win_gdi.cc",
"/third_party/libwebrtc/modules/desktop_capture/window_capturer_win.cc",
"/third_party/libwebrtc/modules/desktop_capture/window_finder_win.cc"
]
if CONFIG["TARGET_CPU"] == "aarch64":
DEFINES["WEBRTC_ARCH_ARM64"] = True
DEFINES["WEBRTC_HAS_NEON"] = True
if CONFIG["TARGET_CPU"] == "arm":
CXXFLAGS += [
"-mfpu=neon"
]
DEFINES["WEBRTC_ARCH_ARM"] = True
DEFINES["WEBRTC_ARCH_ARM_V7"] = True
DEFINES["WEBRTC_HAS_NEON"] = True
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["TARGET_CPU"] == "mips32":
DEFINES["MIPS32_LE"] = True
DEFINES["MIPS_FPU_LE"] = True
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["TARGET_CPU"] == "mips64":
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["TARGET_CPU"] == "ppc64":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["TARGET_CPU"] == "x86":
DEFINES["WEBRTC_ENABLE_AVX2"] = True
if CONFIG["TARGET_CPU"] == "x86_64":
DEFINES["WEBRTC_ENABLE_AVX2"] = True
if CONFIG["MOZ_DEBUG"] == "1" and CONFIG["OS_TARGET"] == "Darwin":
DEFINES["_DEBUG"] = True
if CONFIG["MOZ_DEBUG"] == "1" and CONFIG["OS_TARGET"] == "Linux":
DEFINES["_DEBUG"] = True
if CONFIG["MOZ_DEBUG"] == "1" and CONFIG["OS_TARGET"] == "OpenBSD":
DEFINES["_DEBUG"] = True
if CONFIG["MOZ_DEBUG"] == "1" and CONFIG["OS_TARGET"] == "WINNT":
DEFINES["_HAS_ITERATOR_DEBUGGING"] = "0"
if CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "aarch64":
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "riscv64":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "x86":
CXXFLAGS += [
"-msse2"
]
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "x86_64":
DEFINES["WEBRTC_USE_PIPEWIRE"] = True
DEFINES["_GNU_SOURCE"] = True
LOCAL_INCLUDES += [
"/gfx/angle/checkout/include/",
"/third_party/drm/drm/",
"/third_party/drm/drm/include/",
"/third_party/drm/drm/include/libdrm/",
"/third_party/gbm/gbm/",
"/third_party/libepoxy/libepoxy/include/",
"/third_party/pipewire/"
]
SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/base_capturer_pipewire.cc"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/egl_dmabuf.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/mouse_cursor_monitor_pipewire.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/restore_token_manager.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screen_capture_portal_interface.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_portal.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/screencast_stream_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/wayland/shared_screencast_stream.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "aarch64":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "arm":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "mips32":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "mips64":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "x86":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
if CONFIG["MOZ_X11"] == "1" and CONFIG["OS_TARGET"] == "Linux" and CONFIG["TARGET_CPU"] == "x86_64":
DEFINES["USE_X11"] = "1"
DEFINES["WEBRTC_USE_X11"] = True
OS_LIBS += [
"X11",
"Xcomposite",
"Xdamage",
"Xext",
"Xfixes",
"Xrandr",
"Xrender"
]
UNIFIED_SOURCES += [
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/mouse_cursor_monitor_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/screen_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/shared_x_display.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_capturer_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_finder_x11.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/window_list_utils.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_atom_cache.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_error_trap.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_server_pixel_buffer.cc",
"/third_party/libwebrtc/modules/desktop_capture/linux/x11/x_window_property.cc"
]
Library("desktop_capture_gn")