# Copyright 2019 The Chromium Authors. All rights reserved. # Use of this source code is governed by a BSD-style license that can be # found in the LICENSE file.
"""Implements commands for running and interacting with Fuchsia on AEMU."""
import emu_target import os import platform import qemu_target import logging
from common import GetEmuRootForPlatform
def GetTargetType(): return AemuTarget
class AemuTarget(qemu_target.QemuTarget):
EMULATOR_NAME = 'aemu'
# `VirtioInput` is needed for touch input device support on Fuchsia. # `RefCountPipe` is needed for proper cleanup of resources when a process # that uses Vulkan dies inside the guest
aemu_features = 'VirtioInput,RefCountPipe'
# Configure the CPU to emulate. # On Linux, we can enable lightweight virtualization (KVM) if the host and # guest architectures are the same. if self._IsKvmEnabled():
aemu_features += ',KVM,GLDirectMem,Vulkan' else: if self._target_cpu != 'arm64':
aemu_features += ',-GLDirectMem'
# Use Swiftshader for Vulkan if requested
gpu_target = 'swiftshader_indirect' if self._hardware_gpu:
gpu_target = 'host'
aemu_command = [aemu_path] ifnot self._enable_graphics:
aemu_command.append('-no-window') # All args after -fuchsia flag gets passed to QEMU
aemu_command.extend([ '-feature', aemu_features, '-window-size', '1024x600', '-gpu',
gpu_target, '-verbose', '-fuchsia'
])
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.