Try
export CC=arm-linux-gcc
after running the script. Or better yet, put it in the script. There might be more things that need to be set, but that should be enough to get you going.
Also, if the thing you are trying to compile is using a configure script that calls gtk-config or sdl-config, take a look at those scripts and change them to make them have the right paths. i.e. you don\'t want any references to /usr/lib or other locations of native x86 libraries or you get errors trying to link.