Android Emulator Failed to load libGL.so

Android Emulator on my system failed to find libGL.so which was clearly available in both /usr/lib and /usr/lib64 provided by mesa-libGL.i686 and mesa-libGL.x86_64 respectively. Here is the exact problem I had.

After searching Google extensively, I failed to find something that worked for me. The two prominent answers that came back were as follows.

  • Link libGL.so.1 from /usr/lib to the tools‘ lib folder.

    ln -s /usr/lib/libGL.so.1 ~/android-sdk-linux_x86/tools/lib/libGL.so

Source

  • Another person suggested to install mesa-libGL.i686 which I already had installed.

    yum install mesa-libGL.i686

Source

Since they both failed. I tried to install various packages related to libGL and I found mesa-libGL-devel.x86_64.

So to solve Failed to load libGL.so you need to run following command.