Porting llvm/clang to custom OS.

Recently i become to develop my own posix compilant OS, and as primary compiler selected clang.
But i cannot understand which files me need to edit to add support for my target.
P. S. My OS using ELF format exequtables.
Any help will wery welcome.

You may need/want to add your OS to

and customize everything that uses it.