[tvos] Exclude power_monitor_device_source_ios.mm
This excludes power_monitor_device_source_ios.mm for tvOS since it doesn’t have anything related to battery such as `batteryState` from `UIDevice`. Bug: 391914246 Change-Id: I9dbb11b1e821b9624dfd34eb180ca32224d6fd7d Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/6429465 Reviewed-by: Dave Tapuska <dtapuska@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org> Cr-Commit-Position: refs/heads/main@{#1444413}
This commit is contained in:

committed by
Chromium LUCI CQ

parent
cbd0bd4781
commit
218ac69538
base
@@ -2172,7 +2172,6 @@ component("base") {
|
|||||||
"ios/ns_error_util.h",
|
"ios/ns_error_util.h",
|
||||||
"ios/ns_error_util.mm",
|
"ios/ns_error_util.mm",
|
||||||
"ios/ns_range.h",
|
"ios/ns_range.h",
|
||||||
"power_monitor/power_monitor_device_source_ios.mm",
|
|
||||||
"process/process_metrics_ios.cc",
|
"process/process_metrics_ios.cc",
|
||||||
"process/process_metrics_posix.cc",
|
"process/process_metrics_posix.cc",
|
||||||
"profiler/core_unwinders_ios.cc",
|
"profiler/core_unwinders_ios.cc",
|
||||||
@@ -2210,13 +2209,18 @@ component("base") {
|
|||||||
]
|
]
|
||||||
|
|
||||||
if (target_platform == "tvos") {
|
if (target_platform == "tvos") {
|
||||||
# tvOS apps must be single-process. Build a Process version that does
|
sources += [
|
||||||
# the bare minimum and does not use Mach ports.
|
"power_monitor/power_monitor_device_source_stub.cc",
|
||||||
sources += [ "process/process_tvos.cc" ]
|
|
||||||
|
# tvOS apps must be single-process. Build a Process version that does
|
||||||
|
# the bare minimum and does not use Mach ports.
|
||||||
|
"process/process_tvos.cc",
|
||||||
|
]
|
||||||
} else {
|
} else {
|
||||||
sources += [
|
sources += [
|
||||||
"apple/mach_port_rendezvous_ios.cc",
|
"apple/mach_port_rendezvous_ios.cc",
|
||||||
"apple/mach_port_rendezvous_ios.h",
|
"apple/mach_port_rendezvous_ios.h",
|
||||||
|
"power_monitor/power_monitor_device_source_ios.mm",
|
||||||
"process/process_mac.cc",
|
"process/process_mac.cc",
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -2234,6 +2238,7 @@ component("base") {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
sources += [
|
sources += [
|
||||||
|
"power_monitor/power_monitor_device_source_ios.mm",
|
||||||
"process/launch_ios.cc",
|
"process/launch_ios.cc",
|
||||||
"process/memory_stubs.cc",
|
"process/memory_stubs.cc",
|
||||||
"process/process_stubs.cc",
|
"process/process_stubs.cc",
|
||||||
|
@@ -9,13 +9,13 @@
|
|||||||
namespace base {
|
namespace base {
|
||||||
|
|
||||||
PowerMonitorDeviceSource::PowerMonitorDeviceSource() {
|
PowerMonitorDeviceSource::PowerMonitorDeviceSource() {
|
||||||
#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN)
|
#if (BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_IOS_TVOS)) || BUILDFLAG(IS_WIN)
|
||||||
PlatformInit();
|
PlatformInit();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
PowerMonitorDeviceSource::~PowerMonitorDeviceSource() {
|
PowerMonitorDeviceSource::~PowerMonitorDeviceSource() {
|
||||||
#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN)
|
#if (BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_IOS_TVOS)) || BUILDFLAG(IS_WIN)
|
||||||
PlatformDestroy();
|
PlatformDestroy();
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
@@ -93,7 +93,7 @@ class BASE_EXPORT PowerMonitorDeviceSource : public PowerMonitorSource {
|
|||||||
};
|
};
|
||||||
#endif // BUILDFLAG(IS_WIN)
|
#endif // BUILDFLAG(IS_WIN)
|
||||||
|
|
||||||
#if BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN)
|
#if (BUILDFLAG(IS_APPLE) && !BUILDFLAG(IS_IOS_TVOS)) || BUILDFLAG(IS_WIN)
|
||||||
void PlatformInit();
|
void PlatformInit();
|
||||||
void PlatformDestroy();
|
void PlatformDestroy();
|
||||||
#endif // BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN)
|
#endif // BUILDFLAG(IS_APPLE) || BUILDFLAG(IS_WIN)
|
||||||
|
Reference in New Issue
Block a user