Error of Android Studio: Cannot launch AVD in emulator

I got the following error when I booted an emulator on Android Studio:

Cannot launch AVD in emulator.
Output:
sh: 1: glxinfo: not found
libGL error: unable to load driver: radeonsi_dri.so
libGL error: driver pointer missing
libGL error: failed to load driver: radeonsi
libGL error: unable to load driver: swrast_dri.so
libGL error: failed to load driver: swrast
X Error of failed request:  BadValue (integer parameter out of range for operation)
emulator: WARNING: VM heap size set below hardware specified minimum of 128MB
  Major opcode of failed request:  155 (GLX)
emulator: WARNING: Setting VM heap size to 384MB
  Minor opcode of failed request:  24 (X_GLXCreateNewContext)
  Value in failed request:  0x0
  Serial number of failed request:  33
  Current serial number in output stream:  34
QObject::~QObject: Timers cannot be stopped from another thread

The solution is posted here.

sudo apt-get install lib64stdc++6 (if it is not installed)
cd ~/Android/Sdk/tools/lib64/libstdc++
mv libstdc++.so.6 libstdc++.so.6.original
ln -s /usr/lib64/libstdc++.so.6 ~/Android/Sdk/tools/lib64/libstdc++
sudo apt-get install mesa-utils (if it is not installed)
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s