I am trying to get the Android Emulator working with Ionic 2. Here is my setup...
ANDROID_HOME=/Users/anthonygordon/Library/Android/sdk
JAVA_HOME=/Library/Java/JavaVirtualMachines/jdk1.8.0_65.jdk/Contents/Home
In Android Studio I set up a AVD Nexus_5_API_24
And I get the following error when I run ionic run android
No emulator specified, defaulting to Nexus_5_API_24
Waiting for emulator to start...
[140736250184640]:ERROR:android/android-emu/android/opengl/EmuglBackendScanner.cpp:37:Invalid executable directory: ../emulator
[140736250184640]:ERROR:android/android-emu/android/opengl/EmuglBackendScanner.cpp:37:Invalid executable directory: ../emulator
[140736250184640]:ERROR:android/android-emu/android/qt/qt_setup.cpp:28:Qt library not found at ../emulator/lib64/qt/lib
Could not launch '../emulator/qemu/darwin-x86_64/qemu-system-i386': No such file or directory
Any thoughts ?? I'm stuck
Ok, got a partial answer. I was having this problem when I was trying to launch an emulator with just the regular android sdk command
emulator -avd <name of avd>
When I ran which emulator it pointed to /usr/local/bin/emulator but not the emulator in the android sdk root at /Users/<user name>/Library/Android/sdk/tools/emulator
So I just ran that one with the following.
/Users/<user name>/Library/Android/sdk/tools/emulator -avd <emulator name>
and it launched without a hitch.
I've never used ionic, but I would guess it's pointing to the wrong binary for emulator. Maybe try and remove the emulator binary from the /usr/local/bin?
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With