Skip to content

Glossary

David Griffiths edited this page Apr 18, 2015 · 21 revisions

If you want to be a duck, you need to learn how to quack.

Here are some useful phrases to help you converse in Android.

aapt

The Android Asset Packaging Tool (aapt) is kind of like Java’s jar tool, except instead of compressing .class files into a zip-like .jar file, the aapt tool compresses Dalvik Executable (.dex) files into a zip-like file called an Android Package or .apk file. The .apk file is the standard way to distribute Android apps, and as well as a compiled classes.dex file, it will also include all the resource and manifest files that are needed for your app.

Android Debug Bridge (adb)

This is a server process that runs on your machine and is used to communicate with any connected or virtual Android devices.

Each Android device will run a similar adb process, and the two processes will communicate with each other to form a bridge between your development machine and the Android machine.

And Android Debug Bridge makes it possible to:

  • Send files to and receive files from an Android device
  • Run commands on the Android device
  • Debug apps on the device
  • Open a shell on the device
  • Read logs on the device

Android Virtual Device (AVD)

An Android Virtual Device is an emulated version of an Android device. AVDs run using an emulator called QEMU, and they are emulated rather than simulated. This means that they can run code that is compiled for the CPU of a real device, like an ARM or Intel processor.

Emulation is a lot slower than simulation and that’s why AVDs can be sluggish. You can speed up your device by using Intel’s HAXM Hypervisor.

Dalvik

Dalvik is used to mean one of three things:

  • A bytecode format, analogous to (but different from) the Java .class bytecode format
  • A runtime environment, kind of like the Java Virtual Machine
  • A small town in the North of Iceland

The Dalvik runtime environment was replaced in API 21 with the Android Runtime, but the bytecode format is still used in executable files.

dx

The dx command is used to convert compiled Java `.class= and .jar files into files in Dalvik Executable (.dex) format. The .dex format is the standard byte-code format used by Android apps. The dx command will typically be used to compress all of the Java-compiled code in your app into a single file called classes.dex, which will be then be compressed by the aapt command.

HAXM

Android Virtual Devices are sloooooowwww and that’s because they’re emulated. Every little machine code instruction they want to execute for will need to be interpreted. And that takes a long time.

However… if your development machine runs an Intel processor that supports Virtualization Technology then you can install HAXM.

HAXM allows the Android Emulator to run code from x86-style virtual devices at native speeds. That means, when your AVD needs to execute a series of x86 machine instructions on its virtual CPU, the emulator can simply pass them to your development machines real processor to run them at full speed.

OAT

This is the native library format used with the Android Runtime.

When an app is installed on an Android device, the Dalvik byte-codes in the app are converted into an ELF shared object: that is, a native Linux library.

This library includes not only the native machine code but also the original Dalvik byte-codes, in order to allow the code to be debugged. The format of the converted library is called OAT and the conversion from a .dex file to an OAT file is performed by a tool called dex2oat.

For more information, see How Android Apps are Built and Run

WTF

This means Welcome to Fiskidagurinn, which refers to the Great Fish Day festival held annually in Dalvik, Iceland. Android Developers can often be heard saying My AVD just took 8 minutes to boot up. WTF??? as a tribute to the small town that gave its name to the standard Android executable bytecode format.