I am a computer guy, so I have convinced more than one person to give me their old computers. So I had a 12 year old low end dell server with no ram or hard drive. I wanted to set up a headless development box.
I wanted to set up a headless development box for several reasons. I was used to doing my development on remote servers. A server is easily adminstered, backups etc. are scripted. The cost of a low end cloud server is falling. Many people can share a server, it is nice for showing newbies the ropes, and providing them a development environment for little marginal cost.
I chose Linux because it is free, and I am very practiced at it. It also runs well on the least expensive equipment (free and used.) I chose Debian, I have used it (not exclusivly) since Potato days.
I added a gig of RAM and a refurbished 40 gig harddrive. I was ready to go. I installed Debian Jessie choosing all the defaults, EXCEPT I unchecked "Desktop Environment" at Tasksel.
After some consideration I installed Oracle Java 8. Installation was simple, excepting all of the "do you agree, etc. I redid the instalation several times anyway because I had never done it that way before.
I obtained the android SDK from google, and untarred it into /usr/lib/. Even now I am not sure that was the correct choice, but I wanted it to be in a shared location acessible to all users. I added /usr/lib/android-sdk-linux/tools/ and /usr/lib/android-sdk-linux/platform-tools/ to everyones PATH by adding this line to the end of /etc/bash.bashrc: PATH=$PATH":/usr/lib/android-sdk-linux/tools:/usr/lib/android-sdk-linux/platform-tools"
I created a project with android create project. I leaned a great deal on the help screens.
I tried to build the project with ant. I had not installed it yet. I installed ant. Now it would appear to work but would not work. Hours of Googling. From the results it was obvious that noone knew what the problem was, but that if they flailed enough it went away. There was a clue though. For some people the problem occurred after they had upgraded from version 2x.x.x to version 24.x.x
I had originally installed android-sdk_r24.4.1-linux.tgz. I took a weeks break to get over my frustration, and the I installed android-sdk_r23-linux.tgz. I noticed that adb start-server failed due to a bad execuable. Back to Googling. After digging through a long list of useless search results I came upon the article that I have linked above in reference to 32 bit computers. I installed the backlevel platform tools and everything worked.
-post-build: debug: BUILD SUCCESSFUL Total time: 12 seconds