Building rustc with `allow-old-toolchain`

Hello

I am trying to port rustc to a VLIW processor architecture called Patmos.
To do that, I was given a port of LLVM 3.4 for this architecture.
I then tried to build rustc using x.py, after setting allow-old-toolchain = true, and changing the LLVM directory accordingly with ./configure.
To my surprise, the script kept complaining about the outdated LLVM version.

Am I forgetting something, or doing something wrong ?
How does this flag work ?

This isn't going to work on any current rustc -- there are way too many API differences in LLVM over the years. Even on the master branch, I recently raised the minimum to LLVM 8, and you can see the supporting code that was needed just for LLVM 7.

If you're willing to go way back, even Rust 1.0.0 checks for at least LLVM 3.5 in the configure script. However, if you --disable-llvm-version-check, the only explicit check I see in the code is in src/librustc_trans/trans/debuginfo.rs, which does allow LLVM 3.4.

You won't find much support in the crates ecosystem for such ancient Rust though. Your Rust life will be a lot nicer if you can get ahold of a more current LLVM.

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.