Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/android/228.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Android Emulator在ubuntu 14.04 LTS上不工作_Android_Build_Android Emulator_Emulation - Fatal编程技术网

Android Emulator在ubuntu 14.04 LTS上不工作

Android Emulator在ubuntu 14.04 LTS上不工作,android,build,android-emulator,emulation,Android,Build,Android Emulator,Emulation,我构建了安卓7.0.0_r14,然后进行了模拟,但失败了。 问题是停止“emulator:android\u hw\u fingerprint\u init:fingerprint qemud listen service initialized”,而只是停留在黑屏上。 我不知道该怎么办 这是日志 jinscorp@jinscorp:~/sdk/emulator$ ./emulator @Test7 -verbos unknown option: -verbos please use -help

我构建了安卓7.0.0_r14,然后进行了模拟,但失败了。 问题是停止“emulator:android\u hw\u fingerprint\u init:fingerprint qemud listen service initialized”,而只是停留在黑屏上。 我不知道该怎么办

这是日志

jinscorp@jinscorp:~/sdk/emulator$ ./emulator @Test7 -verbos
unknown option: -verbos
please use -help for a list of valid options
jinscorp@jinscorp:~/sdk/emulator$ ./emulator @Test7 -verbose
emulator:Android emulator version 26.0.0.0 (build_id 3833124)
emulator:Found AVD name 'Test7'
emulator:Found AVD target architecture: arm
emulator:argv[0]: './emulator'; program directory: '/home/jinscorp/sdk/emulator'
emulator:  Found directory: /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a/

emulator:Probing for /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//kernel-ranchu: file exists
emulator:Auto-config: -engine qemu2 (based on configuration)
emulator:  Found directory: /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a/

emulator:try dir /home/jinscorp/sdk/emulator
emulator:Found target-specific 64-bit emulator binary: /home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel
emulator:Adding library search path: '/home/jinscorp/sdk/emulator/lib64'
emulator:Adding library search path: '/home/jinscorp/sdk/emulator/lib64/libstdc++'
emulator:  Found directory: /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a/

emulator:  Found directory: /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a/

emulator:GPU emulation enabled using 'host' mode
emulator: Adding library search path for Qt: '/home/jinscorp/sdk/emulator/lib64/qt/lib'
emulator: Setting Qt plugin search path: QT_QPA_PLATFORM_PLUGIN_PATH=/home/jinscorp/sdk/emulator/lib64/qt/plugins
emulator: Running :/home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel
emulator: qemu backend: argv[00] = "/home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel"
emulator: qemu backend: argv[01] = "@Test7"
emulator: qemu backend: argv[02] = "-verbose"
emulator: Concatenated backend parameters:
 /home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel @Test7 -verbose
emulator: Android virtual device file at: /home/jinscorp/.android/avd/Test7.ini
emulator: virtual device content at /home/jinscorp/.android/avd/Test7.avd
emulator: virtual device config file: /home/jinscorp/.android/avd/Test7.avd/config.ini
emulator: using core hw config path: /home/jinscorp/.android/avd/Test7.avd/hardware-qemu.ini
emulator: Found AVD target API level: 24
emulator: Read property file at /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//build.prop
emulator: No boot.prop property file found.
emulator: found skin 'nexus_6' in directory: /home/jinscorp/sdk/skins/
emulator: autoconfig: -skin nexus_6
emulator: autoconfig: -skindir /home/jinscorp/sdk/skins/
emulator: autoconfig: -kernel /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//kernel-ranchu
emulator: Auto-detect: Kernel image requires new device naming scheme.
emulator: Auto-detect: Kernel does not support YAFFS2 partitions.
emulator: autoconfig: -ramdisk /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//ramdisk.img
emulator: Using initial system image: /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//system.img
emulator: autoconfig: -data /home/jinscorp/.android/avd/Test7.avd/userdata-qemu.img
emulator: autoconfig: -initdata /home/jinscorp/.android/avd/Test7.avd/userdata.img
emulator: autoconfig: -cache /home/jinscorp/.android/avd/Test7.avd/cache.img
emulator: autoconfig: -sdcard /home/jinscorp/.android/avd/Test7.avd/sdcard.img
emulator: Physical RAM size: 1536MB

emulator: VM heap size 256MB is below hardware specified minimum of 384MB,setting it to that value
emulator: System image is read only
emulator: GPU emulation enabled using 'host' mode
emulator: Found 1 DNS servers: 127.0.1.1
emulator: trying to load skin file '/home/jinscorp/sdk/skins//nexus_6/layout'
emulator: WARNING: encryption is off
emulator: Using default value for kernel Contiguous Memory Allocation.
emulator: Found 1 DNS servers: 127.0.1.1
Content of hardware configuration file:
  hw.cpu.arch = arm
  hw.cpu.model = cortex-a8
  hw.cpu.ncore = 2
  hw.ramSize = 1536
  hw.screen = multi-touch
  hw.mainKeys = false
  hw.trackBall = false
  hw.keyboard = true
  hw.keyboard.lid = false
  hw.keyboard.charmap = qwerty2
  hw.dPad = false
  hw.gsmModem = true
  hw.gps = true
  hw.battery = true
  hw.accelerometer = true
  hw.audioInput = true
  hw.audioOutput = true
  hw.sdCard = true
  hw.sdCard.path = /home/jinscorp/.android/avd/Test7.avd/sdcard.img
  disk.cachePartition = true
  disk.cachePartition.path = /home/jinscorp/.android/avd/Test7.avd/cache.img
  disk.cachePartition.size = 66m
  hw.lcd.width = 1440
  hw.lcd.height = 2560
  hw.lcd.depth = 16
  hw.lcd.density = 560
  hw.lcd.backlight = true
  hw.gpu.enabled = true
  hw.gpu.mode = host
  hw.gpu.blacklisted = no
  hw.initialOrientation = Portrait
  hw.camera.back = emulated
  hw.camera.front = emulated
  vm.heapSize = 384
  hw.sensors.light = true
  hw.sensors.pressure = true
  hw.sensors.humidity = true
  hw.sensors.proximity = true
  hw.sensors.magnetic_field = true
  hw.sensors.orientation = true
  hw.sensors.temperature = true
  hw.useext4 = true
  kernel.path = /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//kernel-ranchu
  kernel.newDeviceNaming = yes
  kernel.supportsYaffs2 = no
  disk.ramdisk.path = /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//ramdisk.img
  disk.systemPartition.initPath = /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//system.img
  disk.systemPartition.size = 550m
  disk.dataPartition.path = /home/jinscorp/.android/avd/Test7.avd/userdata-qemu.img
  disk.dataPartition.size = 800m
  avd.name = Test7
.
QEMU options list:
emulator: argv[00] = "/home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel"
emulator: argv[01] = "-dns-server"
emulator: argv[02] = "127.0.1.1"
emulator: argv[03] = "-serial"
emulator: argv[04] = "null"
emulator: argv[05] = "-cpu"
emulator: argv[06] = "cortex-a15"
emulator: argv[07] = "-machine"
emulator: argv[08] = "type=ranchu"
emulator: argv[09] = "-m"
emulator: argv[10] = "1536"
emulator: argv[11] = "-lcd-density"
emulator: argv[12] = "560"
emulator: argv[13] = "-kernel"
emulator: argv[14] = "/home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//kernel-ranchu"
emulator: argv[15] = "-initrd"
emulator: argv[16] = "/home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//ramdisk.img"
emulator: argv[17] = "-object"
emulator: argv[18] = "iothread,id=disk-iothread"
emulator: argv[19] = "-drive"
emulator: argv[20] = "overlap-check=none,cache=unsafe,index=0,id=sdcard,file=/home/jinscorp/.android/avd/Test7.avd/sdcard.img.qcow2,l2-cache-size=1048576"
emulator: argv[21] = "-device"
emulator: argv[22] = "virtio-blk-device,drive=sdcard,iothread=disk-iothread"
emulator: argv[23] = "-drive"
emulator: argv[24] = "overlap-check=none,cache=unsafe,index=1,id=userdata,file=/home/jinscorp/.android/avd/Test7.avd/userdata-qemu.img.qcow2,l2-cache-size=1048576"
emulator: argv[25] = "-device"
emulator: argv[26] = "virtio-blk-device,drive=userdata,iothread=disk-iothread"
emulator: argv[27] = "-drive"
emulator: argv[28] = "overlap-check=none,cache=unsafe,index=2,id=cache,file=/home/jinscorp/.android/avd/Test7.avd/cache.img.qcow2,l2-cache-size=1048576"
emulator: argv[29] = "-device"
emulator: argv[30] = "virtio-blk-device,drive=cache,iothread=disk-iothread"
emulator: argv[31] = "-drive"
emulator: argv[32] = "overlap-check=none,cache=unsafe,index=3,id=system,file=/home/jinscorp/.android/avd/Test7.avd/system.img.qcow2,read-only"
emulator: argv[33] = "-device"
emulator: argv[34] = "virtio-blk-device,drive=system,iothread=disk-iothread"
emulator: argv[35] = "-netdev"
emulator: argv[36] = "user,id=mynet"
emulator: argv[37] = "-device"
emulator: argv[38] = "virtio-net-device,netdev=mynet"
emulator: argv[39] = "-netdev"
emulator: argv[40] = "user,id=mynet2,net=10.0.3.0/24"
emulator: argv[41] = "-device"
emulator: argv[42] = "virtio-net-device,netdev=mynet2"
emulator: argv[43] = "-show-cursor"
emulator: argv[44] = "-L"
emulator: argv[45] = "/home/jinscorp/sdk/emulator/lib/pc-bios"
emulator: argv[46] = "-append"
emulator: argv[47] = "qemu=1 androidboot.hardware=ranchu keep_bootcon earlyprintk=ttyAMA0 android.qemud=1 console=0 console=0 android.checkjni=1 qemu.gles=1"
emulator: argv[48] = "-android-hw"
emulator: argv[49] = "/home/jinscorp/.android/avd/Test7.avd/hardware-qemu.ini"
Concatenated QEMU options:
 /home/jinscorp/sdk/emulator/qemu/linux-x86_64/qemu-system-armel -dns-server 127.0.1.1 -serial null -cpu cortex-a15 -machine type=ranchu -m 1536 -lcd-density 560 -kernel /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//kernel-ranchu -initrd /home/jinscorp/sdk/system-images/android-24/default/armeabi-v7a//ramdisk.img -object iothread,id=disk-iothread -drive overlap-check=none,cache=unsafe,index=0,id=sdcard,file=/home/jinscorp/.android/avd/Test7.avd/sdcard.img.qcow2,l2-cache-size=1048576 -device virtio-blk-device,drive=sdcard,iothread=disk-iothread -drive overlap-check=none,cache=unsafe,index=1,id=userdata,file=/home/jinscorp/.android/avd/Test7.avd/userdata-qemu.img.qcow2,l2-cache-size=1048576 -device virtio-blk-device,drive=userdata,iothread=disk-iothread -drive overlap-check=none,cache=unsafe,index=2,id=cache,file=/home/jinscorp/.android/avd/Test7.avd/cache.img.qcow2,l2-cache-size=1048576 -device virtio-blk-device,drive=cache,iothread=disk-iothread -drive overlap-check=none,cache=unsafe,index=3,id=system,file=/home/jinscorp/.android/avd/Test7.avd/system.img.qcow2,read-only -device virtio-blk-device,drive=system,iothread=disk-iothread -netdev user,id=mynet -device virtio-net-device,netdev=mynet -netdev user,id=mynet2,net=10.0.3.0/24 -device virtio-net-device,netdev=mynet2 -show-cursor -L /home/jinscorp/sdk/emulator/lib/pc-bios -append 'qemu=1 androidboot.hardware=ranchu keep_bootcon earlyprintk=ttyAMA0 android.qemud=1 console=0 console=0 android.checkjni=1 qemu.gles=1' -android-hw /home/jinscorp/.android/avd/Test7.avd/hardware-qemu.ini
emulator: Starting QEMU main loop
emulator: registered 'boot-properties' qemud service
emulator: Adding boot property: 'qemu.sf.fake_camera' = 'both'
emulator: Initializing hardware OpenGLES emulation support
emulator: Adding boot property: 'ro.opengles.version' = '131072'
emulator: Adding boot property: 'dalvik.vm.heapsize' = '384m'
emulator: Adding boot property: 'qemu.hw.mainkeys' = '0'
emulator: Adding boot property: 'qemu.sf.lcd_density' = '560'
emulator: goldfish_events.have-dpad: false
emulator: goldfish_events.have-trackball: false
emulator: goldfish_events.have-camera: true
emulator: goldfish_events.have-keyboard: true
emulator: goldfish_events.have-lidswitch: false
emulator: goldfish_events.have-touch: false
emulator: goldfish_events.have-multitouch: true
emulator: control console listening on port 5554, ADB on port 5555
Not using any http proxy
emulator: android_hw_fingerprint_init: fingerprint qemud listen service initialized

Emulator使用自定义系统映像,这些映像是从它自己的CLs集构建的。我不认为任何CLs都有标签,所以几乎不可能复制与Android Studio和SDK发布的图像完全相同的图像

作为一种解决办法,你可以尝试用你的自定义版本只替换发布的映像上的特定二进制文件——这样它就可以启动了,除非你真的破坏了Android中的某些东西

另外,android_hw_fingerprint_init与您的问题无关——它只是最后一个成功初始化的子系统。别的什么也没做——安卓挂了


p.p.S.您可以尝试添加-show kernel siwtch以获得更多日志记录,并在并行终端中运行“adb logcat”,以便从Android操作系统内部进行诊断。

将emulatorI的堆大小更改为256到1024,但未解决。是否安装了准确的系统映像?请启动sdk管理器检查?我通过sdk管理器安装了映像,然后替换system.img、ramdisk.img,userdata.img是由我构建的。他们成功地建造了大楼,没有出错。在我看来,问题在于指纹。因为我在安卓5.0版本中取得了成功,但安卓6.0或7.0失败了。emulator只是停留在“emulator:android_hw_fingerprint_init:fingerprint qemud listen service initialized”感谢您的回答。我试试看。