Building compiler-rt for foreign target?

I'm developing something for an ARMv7-A system in big-endian mode. I'm
trying to use clang as the compiler for it. Things have been going
well so far, but I've hit a point where the generated code is
depending on functions which are implemented in compiler-rt. Since I'm
doing the building on an amd64 machine, the compiler-rt that I have
only targets x86/amd64. So, I have three overlapping questions:

1. How do I build a compiler-rt for my target processor?

2. Since my target processor supports the hardware divide
instructions, what specific steps do I need to take to ensure that
compiler-rt will use them? (Same applies for several other instruction
set extensions.)

3. Since (again) my target processor supports the hardware divide
instructions, is there a way to get LLVM's code generator to use them
directly instead of calling the EABI division functions? (Same applies
for several other instruction set extensions.)

  1. If you are on Windows you have to make your own build files. You can’t cross-compile using the CMake build system, but you can with the make build system on Linux.

I am on Linux. Are there cross-compiling directions somewhere?