Install one of those chroot apps that give you a distro's package manager on it and then you can. I once did to compile a Qt program on arm. Just install the gcc package and compile away. It was way easier than trying to set up cross-compilation in my Linux box at the time.