Articles

Solution for "ERROR: 32-bit Linux Android emulator binaries are DEPRECATED"


It may happen that when trying to run the Android Emulator from command line (perhaps by using something like daemontools to start the emulator) you stumble upon the following error, even when you're indeed running a 64bit system:

  ERROR: 32-bit Linux Android emulator binaries are DEPRECATED, to use them
       you will have to do at least one of the following:
       - Use the '-force-32bit' option when invoking 'emulator'.
       - Set ANDROID_EMULATOR_FORCE_32BIT to 'true' in your environment.
       Either one will allow you to use the 32-bit binaries, but please be
       aware that these will disappear in a future Android SDK release.
       Consider moving to a 64-bit Linux system before that happens.

To fix this, you have to run the emulator with the SHELL environment variable, which is traditionally set by the login command.

The Android Emulator uses this variable in order to determine if your system is a 32bit or 64bit and then display the message accordingly.

The solution then is to run the emulator by first setting SHELL=/bin/bash, this should fix the issue, and you will be able to run your android emulator instances as system services without first having to login to the system.

Another option is to run the emulator directly by using the emulator64-x86 command.

Enjoy!