-
Bug
-
Resolution: Fixed
-
Blocker
-
Build slave running on Ubuntu 10.04
Android-emulator plugin 2.3
Jenkins 1.478
Android SDK 20.0.3
This problem seems to be an Ubuntu clone of JENKINS-10815.
The relevant portion of my build transcript:
=============================================
$ /usr/android/tools/android list target
[android] Using Android SDK: /usr/android
$ /usr/android/platform-tools/adb start-server
[android] Starting Android emulator
[android] Erasing existing emulator data...
$ /usr/android/tools/emulator -no-boot-anim -ports 38413,41117 -prop persist.sys.language=en -prop persist.sys.country=US -avd hudson_en-US_160_HVGA_android-8 -no-snapshot-load -no-snapshot-save -wipe-data -no-window
- daemon not running. starting it now on port 33846 *
- daemon started successfully *
[android] Emulator did not appear to start; giving up
$ /usr/android/platform-tools/adb disconnect localhost:41117
[android] Stopping Android emulator
$ /usr/android/platform-tools/adb kill-server
==============================================
I tried running the emulator manually as the same user and I got an Google/Android "Send usage" window. I acknowledged this thinking that perhaps the plugin was hanging on this dialog. When that didn't seem to fix the problem I hunted around more and found JENKINS-10815. I tried moving the emulator to emulator.orig and then linking emulator-arm to the name emulator. The resulting build had different errors, but it seemed to successfully detect the running emulator.
After the above work-around
===============================================
$ /usr/android/tools/android list target
[android] Using Android SDK: /usr/android
[android] Creating Android AVD: /home/hudson/.android/avd/hudson_en-US_160_HVGA_android-8.avd
[android] /usr/android/tools/android create avd -f -a -s HVGA -n hudson_en-US_160_HVGA_android-8 -t android-8
$ /usr/android/platform-tools/adb start-server
$ /usr/android/tools/emulator -snapshot-list -no-window -avd hudson_en-US_160_HVGA_android-8
[android] Starting Android emulator and creating initial snapshot
$ /usr/android/tools/emulator -no-boot-anim -ports 56650,46980 -prop persist.sys.language=en -prop persist.sys.country=US -avd hudson_en-US_160_HVGA_android-8 -no-snapshot-load -no-snapshot-save -wipe-data -no-window
waitpid(): No child processes
emulator: ERROR: Could not load OpenGLES emulation library: libOpenglRender.so: cannot open shared object file: No such file or directory
emulator: WARNING: Could not initialize OpenglES emulation, using software renderer.
- daemon not running. starting it now on port 39329 *
- daemon started successfully *
$ /usr/android/platform-tools/adb connect localhost:46980
[android] Waiting for emulator to finish booting...
$ /usr/android/platform-tools/adb -s localhost:46980 shell getprop dev.bootcomplete
$ /usr/android/platform-tools/adb connect localhost:46980
$ /usr/android/platform-tools/adb -s localhost:46980 shell getprop dev.bootcomplete
$ /usr/android/platform-tools/adb connect localhost:46980
$ /usr/android/platform-tools/adb -s localhost:46980 shell getprop dev.bootcomplete
$ /usr/android/platform-tools/adb disconnect localhost:46980
$ /usr/android/platform-tools/adb connect localhost:46980
$ /usr/android/platform-tools/adb -s localhost:46980 shell getprop dev.bootcomplete
$ /usr/android/platform-tools/adb -s localhost:46980 logcat -v time
[android] Giving the system some time to settle before creating initial snapshot...
$ /usr/android/platform-tools/adb connect localhost:46980
$ /usr/android/platform-tools/adb -s localhost:46980 logcat -c
$ /usr/android/platform-tools/adb -s localhost:46980 shell log -p v -t Jenkins "Creating snapshot..."
[android] Creating snapshot...
$ /usr/android/platform-tools/adb connect localhost:46980
[android] Emulator is ready for use (took 86 seconds)
================================================