blob: e4137bc401b4d820918eb8367c96af2b7eabab70 [file] [log] [blame]
# Copyright 2021 The Cobalt Authors. All Rights Reserved.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
config("starboard_platform_config") {
cflags_cc = [
"/ZW", # Windows Runtime
"/ZW:nostdlib", # Windows Runtime, no default #using
]
defines = [
# VS2017 always defines this for UWP apps
"WINAPI_FAMILY=WINAPI_FAMILY_APP",
# VS2017 always defines this for UWP apps
"__WRL_NO_DEFAULT_LIB__",
]
}
static_library("starboard_platform") {
sources = [
"//starboard/shared/egl/system_egl.cc",
"//starboard/shared/gles/system_gles2.cc",
"//starboard/shared/opus/opus_audio_decoder.cc",
"//starboard/shared/opus/opus_audio_decoder.h",
"//starboard/shared/starboard/decode_target/decode_target_context_runner.cc",
"//starboard/shared/starboard/decode_target/decode_target_context_runner.h",
"//starboard/shared/starboard/drm/drm_close_session.cc",
"//starboard/shared/starboard/drm/drm_destroy_system.cc",
"//starboard/shared/starboard/drm/drm_generate_session_update_request.cc",
"//starboard/shared/starboard/drm/drm_get_metrics.cc",
"//starboard/shared/starboard/drm/drm_is_server_certificate_updatable.cc",
"//starboard/shared/starboard/drm/drm_system_internal.h",
"//starboard/shared/starboard/drm/drm_update_server_certificate.cc",
"//starboard/shared/starboard/drm/drm_update_session.cc",
"//starboard/shared/starboard/localized_strings.cc",
"//starboard/shared/starboard/media/media_can_play_mime_and_key_system.cc",
"//starboard/shared/starboard/media/media_get_audio_buffer_budget.cc",
"//starboard/shared/starboard/media/media_get_audio_output_count_single_audio_output.cc",
"//starboard/shared/starboard/media/media_get_buffer_alignment.cc",
"//starboard/shared/starboard/media/media_get_buffer_allocation_unit.cc",
"//starboard/shared/starboard/media/media_get_buffer_garbage_collection_duration_threshold.cc",
"//starboard/shared/starboard/media/media_get_buffer_padding.cc",
"//starboard/shared/starboard/media/media_get_buffer_storage_type.cc",
"//starboard/shared/starboard/media/media_get_initial_buffer_capacity.cc",
"//starboard/shared/starboard/media/media_get_progressive_buffer_budget.cc",
"//starboard/shared/starboard/media/media_get_video_buffer_budget.cc",
"//starboard/shared/starboard/media/media_is_buffer_pool_allocate_on_demand.cc",
"//starboard/shared/starboard/media/media_is_buffer_using_memory_pool.cc",
"//starboard/shared/starboard/memory.cc",
"//starboard/shared/starboard/microphone/microphone_close.cc",
"//starboard/shared/starboard/microphone/microphone_create.cc",
"//starboard/shared/starboard/microphone/microphone_destroy.cc",
"//starboard/shared/starboard/microphone/microphone_get_available.cc",
"//starboard/shared/starboard/microphone/microphone_internal.h",
"//starboard/shared/starboard/microphone/microphone_is_sample_rate_supported.cc",
"//starboard/shared/starboard/microphone/microphone_open.cc",
"//starboard/shared/starboard/microphone/microphone_read.cc",
"//starboard/shared/starboard/player/filter/audio_frame_tracker.cc",
"//starboard/shared/starboard/player/filter/audio_frame_tracker.h",
"//starboard/shared/starboard/player/filter/audio_renderer_internal.h",
"//starboard/shared/starboard/player/filter/audio_renderer_internal_pcm.cc",
"//starboard/shared/starboard/player/filter/audio_renderer_internal_pcm.h",
"//starboard/shared/starboard/player/filter/audio_renderer_sink.h",
"//starboard/shared/starboard/player/filter/audio_renderer_sink_impl.cc",
"//starboard/shared/starboard/player/filter/audio_renderer_sink_impl.h",
"//starboard/shared/starboard/player/filter/audio_resampler_impl.cc",
"//starboard/shared/starboard/player/filter/audio_time_stretcher.cc",
"//starboard/shared/starboard/player/filter/decoded_audio_queue.cc",
"//starboard/shared/starboard/player/filter/filter_based_player_worker_handler.cc",
"//starboard/shared/starboard/player/filter/media_time_provider.h",
"//starboard/shared/starboard/player/filter/media_time_provider_impl.cc",
"//starboard/shared/starboard/player/filter/media_time_provider_impl.h",
"//starboard/shared/starboard/player/filter/video_frame_internal.h",
"//starboard/shared/starboard/player/filter/video_render_algorithm.h",
"//starboard/shared/starboard/player/filter/video_render_algorithm_impl.cc",
"//starboard/shared/starboard/player/filter/video_render_algorithm_impl.h",
"//starboard/shared/starboard/player/filter/video_renderer_internal.h",
"//starboard/shared/starboard/player/filter/video_renderer_internal_impl.cc",
"//starboard/shared/starboard/player/filter/video_renderer_internal_impl.h",
"//starboard/shared/starboard/player/filter/wsola_internal.cc",
"//starboard/shared/starboard/system_request_blur.cc",
"//starboard/shared/starboard/system_request_conceal.cc",
"//starboard/shared/starboard/system_request_focus.cc",
"//starboard/shared/starboard/system_request_freeze.cc",
"//starboard/shared/starboard/system_request_reveal.cc",
"//starboard/shared/starboard/system_request_stop.cc",
"//starboard/shared/starboard/system_supports_resume.cc",
"//starboard/shared/stub/media_set_audio_write_duration.cc",
"//starboard/shared/stub/system_symbolize.cc",
"//starboard/shared/uwp/analog_thumbstick_input.cc",
"//starboard/shared/uwp/analog_thumbstick_input.h",
"//starboard/shared/uwp/analog_thumbstick_input_thread.cc",
"//starboard/shared/uwp/analog_thumbstick_input_thread.h",
"//starboard/shared/uwp/application_uwp.cc",
"//starboard/shared/uwp/application_uwp.h",
"//starboard/shared/uwp/application_uwp_key_event.cc",
"//starboard/shared/uwp/async_utils.h",
"//starboard/shared/uwp/audio_renderer_passthrough.cc",
"//starboard/shared/uwp/audio_renderer_passthrough.h",
"//starboard/shared/uwp/decoder_utils.cc",
"//starboard/shared/uwp/decoder_utils.h",
"//starboard/shared/uwp/extended_resources_manager.cc",
"//starboard/shared/uwp/extended_resources_manager.h",
"//starboard/shared/uwp/get_home_directory.cc",
"//starboard/shared/uwp/keys.h",
"//starboard/shared/uwp/log_file_impl.cc",
"//starboard/shared/uwp/log_file_impl.h",
"//starboard/shared/uwp/log_raw.cc",
"//starboard/shared/uwp/log_raw_format.cc",
"//starboard/shared/uwp/log_writer_interface.h",
"//starboard/shared/uwp/log_writer_uwp.cc",
"//starboard/shared/uwp/log_writer_uwp.h",
"//starboard/shared/uwp/log_writer_win32.cc",
"//starboard/shared/uwp/log_writer_win32.h",
"//starboard/shared/uwp/media_get_audio_configuration.cc",
"//starboard/shared/uwp/media_is_audio_supported.cc",
"//starboard/shared/uwp/media_is_video_supported.cc",
"//starboard/shared/uwp/microphone_impl.cc",
"//starboard/shared/uwp/player_components_factory.cc",
"//starboard/shared/uwp/system_get_device_type.cc",
"//starboard/shared/uwp/system_get_property.cc",
"//starboard/shared/uwp/system_get_total_cpu_memory.cc",
"//starboard/shared/uwp/system_get_used_cpu_memory.cc",
"//starboard/shared/uwp/system_platform_error_internal.cc",
"//starboard/shared/uwp/system_platform_error_internal.h",
"//starboard/shared/uwp/system_raise_platform_error.cc",
"//starboard/shared/uwp/wasapi_audio.cc",
"//starboard/shared/uwp/wasapi_audio.h",
"//starboard/shared/uwp/wasapi_audio_sink.cc",
"//starboard/shared/uwp/wasapi_audio_sink.h",
"//starboard/shared/uwp/watchdog_log.cc",
"//starboard/shared/uwp/watchdog_log.h",
"//starboard/shared/uwp/window_create.cc",
"//starboard/shared/uwp/window_destroy.cc",
"//starboard/shared/uwp/window_get_diagonal_size_in_inches.cc",
"//starboard/shared/uwp/window_get_platform_handle.cc",
"//starboard/shared/uwp/window_get_size.cc",
"//starboard/shared/uwp/window_internal.cc",
"//starboard/shared/uwp/window_internal.h",
"//starboard/shared/uwp/window_set_default_options.cc",
"//starboard/shared/uwp/xb1_get_type.cc",
"//starboard/shared/uwp/xb1_get_type.h",
"//starboard/shared/uwp/xb1_media_session_client.cc",
"//starboard/shared/uwp/xb1_media_session_client.h",
"//starboard/shared/win32/atomic_queue.h",
"//starboard/shared/win32/audio_decoder.cc",
"//starboard/shared/win32/audio_decoder.h",
"//starboard/shared/win32/audio_decoder_thread.cc",
"//starboard/shared/win32/audio_decoder_thread.h",
"//starboard/shared/win32/audio_transform.cc",
"//starboard/shared/win32/audio_transform.h",
"//starboard/shared/win32/decode_target_internal.cc",
"//starboard/shared/win32/decode_target_internal.h",
"//starboard/shared/win32/decrypting_decoder.cc",
"//starboard/shared/win32/decrypting_decoder.h",
"//starboard/shared/win32/drm_system_playready.cc",
"//starboard/shared/win32/drm_system_playready.h",
"//starboard/shared/win32/dx_context_video_decoder.cc",
"//starboard/shared/win32/dx_context_video_decoder.h",
"//starboard/shared/win32/hardware_decode_target_internal.cc",
"//starboard/shared/win32/hardware_decode_target_internal.h",
"//starboard/shared/win32/media_common.cc",
"//starboard/shared/win32/media_common.h",
"//starboard/shared/win32/media_foundation_utils.cc",
"//starboard/shared/win32/media_foundation_utils.h",
"//starboard/shared/win32/media_get_max_buffer_capacity.cc",
"//starboard/shared/win32/media_transform.cc",
"//starboard/shared/win32/media_transform.h",
# TODO (b/304335954): Use uwp implementation for correct IANA name once
# daylight savings offset is fixed.
"//starboard/shared/win32/time_zone_get_name.cc",
"//starboard/shared/win32/video_decoder.cc",
"//starboard/shared/win32/video_decoder.h",
"//starboard/shared/win32/win32_audio_decoder.cc",
"//starboard/shared/win32/win32_audio_decoder.h",
"//starboard/shared/win32/wrm_header.cc",
"//starboard/shared/win32/wrm_header.h",
"//starboard/xb1/shared/gpu_base_video_decoder.cc",
"//starboard/xb1/shared/gpu_base_video_decoder.h",
"//starboard/xb1/shared/internal_shims.h",
"//starboard/xb1/shared/playready_license.cc",
"//starboard/xb1/shared/video_decoder_uwp.cc",
"//starboard/xb1/shared/video_decoder_uwp.h",
"//starboard/xb1/shared/video_frame_impl.h",
"atomic_public.h",
"configuration_public.h",
"shared/configuration.cc",
"shared/configuration.h",
"shared/configuration_constants.cc",
"shared/system_get_extensions.cc",
"shared/system_get_path.cc",
]
configs += [
"//starboard/build/config:starboard_implementation",
"//starboard/win/shared:starboard_platform_config",
]
public_deps = [ "//starboard/win/shared:starboard_platform" ]
deps = [
"//third_party/angle:translator",
"//third_party/opus",
]
if (is_internal_build) {
sources += [
"//internal/starboard/shared/uwp/keys.cc",
"//internal/starboard/xb1/dav1d_video_decoder.cc",
"//internal/starboard/xb1/dav1d_video_decoder.h",
"//internal/starboard/xb1/drm_create_system.cc",
"//internal/starboard/xb1/internal_shims.cc",
"//internal/starboard/xb1/media_is_supported.cc",
"//internal/starboard/xb1/oemcrypto_engine_device_properties_xb1.cc",
"//internal/starboard/xb1/system_sign_with_certification_secret_key.cc",
"//internal/starboard/xb1/vpx_video_decoder.cc",
"//internal/starboard/xb1/vpx_video_decoder.h",
"//starboard/keyboxes/xbox/system_properties.cc",
"//starboard/shared/widevine/drm_system_widevine.cc",
"//starboard/shared/widevine/drm_system_widevine.h",
"//starboard/shared/widevine/widevine_storage.cc",
"//starboard/shared/widevine/widevine_storage.h",
"//starboard/shared/widevine/widevine_timer.cc",
"//starboard/shared/widevine/widevine_timer.h",
]
deps += [
"//starboard/shared/widevine:oemcrypto",
"//third_party/internal/ce_cdm/cdm:widevine_cdm_core",
"//third_party/internal/ce_cdm/cdm:widevine_ce_cdm_static",
"//third_party/internal/dav1d_gpu/xb1:dav1d_xb1",
"//third_party/internal/libvpx_xb1",
]
} else {
sources += [
"//starboard/shared/stub/drm_create_system.cc",
"//starboard/shared/stub/media_is_supported.cc",
"//starboard/shared/stub/system_sign_with_certification_secret_key.cc",
"//starboard/shared/uwp/keys.cc",
"//starboard/xb1/public_system_properties.cc",
"//starboard/xb1/shared/internal_stubs.cc",
]
}
}