Wednesday, May 24, 2017

Problems when trying to setup Android Studio on Ubuntu


Had 2 problems

first


Unable to run mksdcard SDK tool.

solved by

sudo apt-get install lib32z1 lib32ncurses5 lib32bz2-1.0 lib32stdc++6

Second, while trying to launch emulator from within Android Studio

libGL error: unable to load driver: i965_dri.solibGL error: driver pointer missinglibGL

solved by

either run this command from the terminal


LD_PRELOAD='/usr/lib/x86_64-linux-gnu/libstdc++.so.6' /Android/Sdk/tools/emulator -netdelay none -netspeed full -avd Nexus_5_API_24

or, set the ennvironment variable
ANDROID_EMULATOR_USE_SYSTEM_LIBS to 1

in ~/.pam_environment


and re-login