Cross compiler default include path setup
===

First, some background:  I'm attempting to write drivers and applications for Android on the Beagleboard-xM.  

I've downloaded their android development kit, installed it, and can succesfully build everything in it using the directions at http://processors.wiki.ti.com/index.php/TI-Android-ICS-4.0.3-DevKit-3.0.0_DevelopersGuide

I've been able to make my own skeleton kernel module following the steps in http://tldp.org/LDP/lkmpg/2.6/lkmpg.pdf without issues. I can copy the .ko file to the android device, insmod, rmmod, etc. 

I got tired of the basic shell given by the default build and thought I'd add busybox.  I tried following the directions at ht tp://omapp edia.org/wiki/Android_Installing_Busybox_Command_Line_Tools, but I get a compile error on standard libc header files.

After digging around quite a bit, I've determined that the pre-built cross compiler provided in the TI android development kit wasn't searching the right paths.  

I confirmed this by creating my own .c file that included <stdio.h> and tried to compile it with 
**arm-eabi-gcc blah.c -o blah** 
and was met with the same results (unable to find the header file in question)

**'arm-eabi-gcc -print-prog-name=cc1' -v** gives me this:

 - ignoring nonexistent directory
   "/usr/local/google/home/android/cupcake_rel_root/usr/local/include"
 - ignoring nonexistent directory "/usr/local/lib/gcc/arm-eabi/4.4.3/include" 
 - ignoring nonexistent directory "/usr/local/lib/gcc/arm-eabi/4.4.3/include-fixed"
 - ignoring nonexistent directory "/usr/local/lib/../arm-eabi/include" 
 - ignoring nonexistent directory "/usr/local/google/home/android/cupcake_rel_root/usr/include"


None of these paths ever existed on my fresh install of ubuntu 10.04.  My cross compiler I used is at **/usr/TI-Android/prebuilt/linux-86/toolchain/arm-eabi-4.4.3/**.   I didn't do anything except run the bit .bin file that was the android development kit (which seemed more like simply extracting itself from the .bin file; I don't remember it doing anything else)

So, a few questions:  

 1. how the heck did everything else (i.e. android, x-loader, u-boot, the kernel) build by just putting the bin of the cross compile tool into $PATH (like the how-to documents say).  I assume it (make menuconfig?) does some magic in fixing up the include paths based on the location of the executable, but...
 2. Why doesn't busybox work the same way since it seems to be built with a similar looking infrastructure?
 2. How do I make it so I can cross compile my own applications?

I assume I've missed a step and should have done some sort of install/configure on the pre-built cross compiler, but information is horribly scant.   I appeal to you, open source gods, to point my way across this dark and stormy sea.

(p.s. sorry for mangling the third HTTP, the system wouldn't let me post more than 2 at my reputation level)