If you want to set up a remote build machine for an Android project, one of the first obstacles you’ll encounter is how to install the SDK from the command line. Both the SDK installer and AVD Manager are designed to be run graphically. Fortunately, there are some options for command line setups.
First thing you’ll need to do is download the SDK tools. You probably just need the SDK Tools tgz file for a linux install. You do not need the ADT Eclipse plugin, nor the ADT bundle. Those all need a GUI.
Then, after unpacking that file, you’ll need to set up the environment variables and install the actual platform SDKs. There are SDKs for the different APIs you can target (ie, API 15, API 19, etc), so you’ll need to know what you’re aiming at. Google has some old information about how to install those SDKs on a headless machine, but here are all the steps themselves, as well as some caveats.
Continue reading →