Skip to content

Commit b062f91

Browse files
committed
Distinguish toolchain
Signed-off-by: xizheyin <[email protected]>
1 parent b1228b0 commit b062f91

File tree

1 file changed

+10
-3
lines changed

1 file changed

+10
-3
lines changed

src/doc/unstable-book/src/language-features/rustc-private.md

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ that is necessary for linking against dylibs that statically link `std` (such as
1313
This makes this feature "viral" in linkage; its use in a given crate makes its use required in
1414
dependent crates which link to it (including integration tests, which are built as separate crates).
1515

16+
## Required Components
1617

18+
### When using `rustc-private` with Official Toolchains
1719

18-
### Required Components
19-
20-
To use the `rustc_private` feature, you need to install:
20+
When using the `rustc_private` feature with official toolchains distributed via rustup, you'll need to install:
2121

2222
1. The `rustc-dev` component (provides compiler libraries)
2323
2. The `llvm-tools` component (provides LLVM libraries needed for linking)
@@ -35,3 +35,10 @@ error: linking with `cc` failed: exit status: 1
3535
|
3636
= note: rust-lld: error: unable to find library -lLLVM-{version}
3737
```
38+
39+
### When using `rustc-private` with Custom Toolchains
40+
41+
For custom-built toolchains or environments not using rustup, different configuration may be required:
42+
43+
- Ensure LLVM libraries are available in your library search paths
44+
- You might need to configure library paths explicitly depending on your LLVM installation

0 commit comments

Comments
 (0)