With nixpkgs's rustc, rust-src component is not bundled with the compiler by default and is instead provided from a separate store path, so this assumption does not hold. The assertion assumes these paths are in the same location which causes `make LLVM=1 rust-analyzer` to fail on NixOS.
Unified · Split
| @@ -213,9 +213,6 @@ def main(): · 212 unmodified lines | |||
| 213 | level=logging.INFO if args.verbose else logging.WARNING | 213 | level=logging.INFO if args.verbose else logging.WARNING |
| 214 | ) | 214 | ) |
| 215 | 215 | ||
| 216 | # Making sure that the `sysroot` and `sysroot_src` belong to the same toolchain. | ||
| 217 | assert args.sysroot in args.sysroot_src.parents | ||
| 218 | |||
| 219 | rust_project = { | 216 | rust_project = { |
| 220 | "crates": generate_crates(args.srctree, args.objtree, args.sysroot_src, args.exttree, args.cfgs, args.core_edition), | 217 | "crates": generate_crates(args.srctree, args.objtree, args.sysroot_src, args.exttree, args.cfgs, args.core_edition), |
| 221 | "sysroot": str(args.sysroot), | 218 | "sysroot": str(args.sysroot), |