I’ve been experimenting with building LLVM/clang/lld as an Irix toolchain. Some of this is motivated by the fact that professionally I need to stay away from anything GPLv3 and the rest is motivated by the fact that I know a lot of people involved with LLVM and can thus easily ask for their help.
So far I’ve been able to compile a hello world program to a .o but not an executable, and I can’t link the .o on Irix because it appears not to grok some of the ELF features lld is using. Attempting to link on Linux is getting an error due to an unresolved symbol in libc.so, which would normally be filled in by rld. I’ve asked for assistance with this stuff on the cfe-dev list and so far the help has been useful; I figured bringing it up here would be useful too in either inspiring someone else to try something similar or to help debug it.
One thing I can’t do without jumping through a bunch of hoops, alas, is share my code. Hopefully I’ve been detailed enough in my questions that someone else could git clone LLVM’s new monorepo and reproduce my results.
Oh yeah, and to make an Irix SDK, I tarred up the following directories on my Octane with Irix 6.5.30f and MIPSpro 7.4.4m installed:
Then I just extracted them into a directory on my Linux box to pass as -isysroot to the compiler. If there’s anything else that I should grab, please let me know.
So far I’ve been able to compile a hello world program to a .o but not an executable, and I can’t link the .o on Irix because it appears not to grok some of the ELF features lld is using. Attempting to link on Linux is getting an error due to an unresolved symbol in libc.so, which would normally be filled in by rld. I’ve asked for assistance with this stuff on the cfe-dev list and so far the help has been useful; I figured bringing it up here would be useful too in either inspiring someone else to try something similar or to help debug it.
One thing I can’t do without jumping through a bunch of hoops, alas, is share my code. Hopefully I’ve been detailed enough in my questions that someone else could git clone LLVM’s new monorepo and reproduce my results.
Oh yeah, and to make an Irix SDK, I tarred up the following directories on my Octane with Irix 6.5.30f and MIPSpro 7.4.4m installed:
- /usr/include
- /lib
- /usr/lib
- /lib32
- /usr/lib32
- /lib64
- /usr/lib64
Then I just extracted them into a directory on my Linux box to pass as -isysroot to the compiler. If there’s anything else that I should grab, please let me know.