Skip to content
Merged
Prev Previous commit
Next Next commit
replace config.toml to bootstrap.toml in src:doc:rustc
  • Loading branch information
Shourya742 committed Mar 17, 2025
commit 85e9da8e60d7d46b6a12486cbe105bd914e29128
2 changes: 1 addition & 1 deletion src/doc/rustc/src/instrument-coverage.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Rust's source-based code coverage requires the Rust "profiler runtime". Without

The Rust `nightly` distribution channel includes the profiler runtime, by default.

> **Important**: If you are building the Rust compiler from the source distribution, the profiler runtime is _not_ enabled in the default `config.example.toml`. Edit your `config.toml` file and ensure the `profiler` feature is set it to `true` (either under the `[build]` section, or under the settings for an individual `[target.<triple>]`):
> **Important**: If you are building the Rust compiler from the source distribution, the profiler runtime is _not_ enabled in the default `bootstrap.example.toml`. Edit your `bootstrap.toml` file and ensure the `profiler` feature is set it to `true` (either under the `[build]` section, or under the settings for an individual `[target.<triple>]`):
>
> ```toml
> # Build the profiler runtime (required when compiling with options that depend
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/TEMPLATE.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ What format do binaries use by default? ELF, PE, something else?
## Building the target

If Rust doesn't build the target by default, how can users build it? Can users
just add it to the `target` list in `config.toml`?
just add it to the `target` list in `bootstrap.toml`?

## Building Rust programs

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ exec /path/to/ohos-sdk/linux/native/llvm/bin/clang++ \

## Building the target

To build a rust toolchain, create a `config.toml` with the following contents:
To build a rust toolchain, create a `bootstrap.toml` with the following contents:

```toml
profile = "compiler"
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/apple-ios.md
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ $ rustup target add x86_64-apple-ios
```

The tier 3 targets can be built by enabling them for a `rustc` build in
`config.toml`, by adding, for example:
`bootstrap.toml`, by adding, for example:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/apple-tvos.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ The following APIs are currently known to have missing or incomplete support:
## Building the target

The targets can be built by enabling them for a `rustc` build in
`config.toml`, by adding, for example:
`bootstrap.toml`, by adding, for example:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/apple-visionos.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ case `XROS_DEPLOYMENT_TARGET`.
## Building the target

The targets can be built by enabling them for a `rustc` build in
`config.toml`, by adding, for example:
`bootstrap.toml`, by adding, for example:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/apple-watchos.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ case `WATCHOS_DEPLOYMENT_TARGET`.
## Building the target

The targets can be built by enabling them for a `rustc` build in
`config.toml`, by adding, for example:
`bootstrap.toml`, by adding, for example:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/arm64e-apple-darwin.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ See the docs on [`*-apple-darwin`](apple-darwin.md) for general macOS requiremen

## Building the target

You can build Rust with support for the targets by adding it to the `target` list in `config.toml`:
You can build Rust with support for the targets by adding it to the `target` list in `bootstrap.toml`:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/arm64e-apple-ios.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ See the docs on [`*-apple-ios`](apple-ios.md) for general iOS requirements.

## Building the target

You can build Rust with support for the targets by adding it to the `target` list in `config.toml`:
You can build Rust with support for the targets by adding it to the `target` list in `bootstrap.toml`:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/arm64e-apple-tvos.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ To build this target Xcode 12 or higher on macOS is required.

## Building the target

You can build Rust with support for the targets by adding it to the `target` list in `config.toml`:
You can build Rust with support for the targets by adding it to the `target` list in `bootstrap.toml`:

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ To put this in practice:
## Building the target

You can build Rust with support for the targets by adding it to the `target`
list in `config.toml`:
list in `bootstrap.toml`:

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ The target definition can be seen [here](https://github.com/rust-lang/rust/blob/
## Building the target
Because it is Tier 3, rust does not yet ship pre-compiled artifacts for this target.

Therefore, you can build Rust with support for the target by adding it to the target list in config.toml, a sample configuration is shown below. It is expected that the user already have a working GNU compiler toolchain and update the paths accordingly.
Therefore, you can build Rust with support for the target by adding it to the target list in bootstrap.toml, a sample configuration is shown below. It is expected that the user already have a working GNU compiler toolchain and update the paths accordingly.

```toml
[llvm]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/armv6k-nintendo-3ds.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ This target generates binaries in the ELF format.
## Building the target

You can build Rust with support for the target by adding it to the `target`
list in `config.toml` and providing paths to the devkitARM toolchain.
list in `bootstrap.toml` and providing paths to the devkitARM toolchain.

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ If you don't already have a suitable toolchain, download one [here](https://tool

### Configure rust

The target can be built by enabling it for a `rustc` build, by placing the following in `config.toml`:
The target can be built by enabling it for a `rustc` build, by placing the following in `bootstrap.toml`:

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ If you don't already have a suitable toolchain, you can download from [here](htt

### Configure rust

The target can be built by enabling it for a `rustc` build, by placing the following in `config.toml`:
The target can be built by enabling it for a `rustc` build, by placing the following in `bootstrap.toml`:

```toml
[build]
Expand Down
10 changes: 5 additions & 5 deletions src/doc/rustc/src/platform-support/fuchsia.md
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ Fuchsia as well. A recent version (14+) of clang should be sufficient to compile
Rust for Fuchsia.

x86-64 and AArch64 Fuchsia targets can be enabled using the following
configuration in `config.toml`:
configuration in `bootstrap.toml`:

```toml
[build]
Expand Down Expand Up @@ -212,7 +212,7 @@ cxx = "clang++"

By default, the Rust compiler installs itself to `/usr/local` on most UNIX
systems. You may want to install it to another location (e.g. a local `install`
directory) by setting a custom prefix in `config.toml`:
directory) by setting a custom prefix in `bootstrap.toml`:

```toml
[install]
Expand Down Expand Up @@ -695,7 +695,7 @@ We can then use the script to start our test environment with:
)
```

Where `${RUST_SRC_PATH}/build` is the `build-dir` set in `config.toml`.
Where `${RUST_SRC_PATH}/build` is the `build-dir` set in `bootstrap.toml`.

Once our environment is started, we can run our tests using `x.py` as usual. The
test runner script will run the compiled tests on an emulated Fuchsia device. To
Expand All @@ -705,7 +705,7 @@ run the full `tests/ui` test suite:
( \
source config-env.sh && \
./x.py \
--config config.toml \
--config bootstrap.toml \
--stage=2 \
test tests/ui \
--target x86_64-unknown-fuchsia \
Expand Down Expand Up @@ -893,7 +893,7 @@ through our `x.py` invocation. The full invocation is:
( \
source config-env.sh && \
./x.py \
--config config.toml \
--config bootstrap.toml \
--stage=2 \
test tests/${TEST} \
--target x86_64-unknown-fuchsia \
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/hermit.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ Hermit binaries have the ELF format.

## Building the target

You can build Rust with support for the targets by adding it to the `target` list in `config.toml`.
You can build Rust with support for the targets by adding it to the `target` list in `bootstrap.toml`.
To run the Hermit build scripts, you also have to enable your host target.
The build scripts rely on `llvm-tools` and binaries are linked using `rust-lld`, so those have to be enabled as well.

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ Because it is Tier 3, rust does not yet ship pre-compiled artifacts for this
target.

Therefore, you can build Rust with support for the target by adding it to the
target list in `config.toml`, a sample configuration is shown below.
target list in `bootstrap.toml`, a sample configuration is shown below.

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ This target generates PIC ELF binaries.
## Building the target

You can build Rust with support for the target by adding it to the `target`
list in `config.toml`:
list in `bootstrap.toml`:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/i686-apple-darwin.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ You'll need the macOS 10.13 SDK shipped with Xcode 9. The location of the SDK
can be passed to `rustc` using the common `SDKROOT` environment variable.

Once you have that, you can build Rust with support for the target by adding
it to the `target` list in `config.toml`:
it to the `target` list in `bootstrap.toml`:

```toml
[build]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/kmc-solid.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ The target can be built by enabling it for a `rustc` build.
target = ["aarch64-kmc-solid_asp3"]
```

Make sure `aarch64-kmc-elf-gcc` is included in `$PATH`. Alternatively, you can use GNU Arm Embedded Toolchain by adding the following to `config.toml`:
Make sure `aarch64-kmc-elf-gcc` is included in `$PATH`. Alternatively, you can use GNU Arm Embedded Toolchain by adding the following to `bootstrap.toml`:

```toml
[target.aarch64-kmc-solid_asp3]
Expand Down
4 changes: 2 additions & 2 deletions src/doc/rustc/src/platform-support/loongarch-linux.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,15 +65,15 @@ These targets are distributed through `rustup`, and otherwise require no
special configuration.

If you need to build your own Rust for some reason though, the targets can be
simply enabled in `config.toml`. For example:
simply enabled in `bootstrap.toml`. For example:

```toml
[build]
target = ["loongarch64-unknown-linux-gnu"]
```

Make sure the LoongArch toolchain binaries are reachable from `$PATH`.
Alternatively, you can explicitly configure the paths in `config.toml`:
Alternatively, you can explicitly configure the paths in `bootstrap.toml`:

```toml
[target.loongarch64-unknown-linux-gnu]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/loongarch-none.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ scripts.
## Building the target

You can build Rust with support for the targets by adding them to the `target`
list in `config.toml`:
list in `bootstrap.toml`:

```toml
[build]
Expand Down
6 changes: 3 additions & 3 deletions src/doc/rustc/src/platform-support/mips-release-6.md
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ The following procedure outlines the build process for the MIPS64 R6 target with

### Prerequisite: Disable debuginfo

An LLVM bug makes rustc crash if debug or debug info generation is enabled. You need to edit `config.toml` to disable this:
An LLVM bug makes rustc crash if debug or debug info generation is enabled. You need to edit `bootstrap.toml` to disable this:

```toml
[rust]
Expand All @@ -83,7 +83,7 @@ The crate `rustix` may try to link itself against MIPS R2 assembly, resulting in
export RUSTFLAGS="--cfg rustix_use_libc"
```

This will trigger warnings during build, as `-D warnings` is enabled by default. Disable `-D warnings` by editing `config.toml` to append the following:
This will trigger warnings during build, as `-D warnings` is enabled by default. Disable `-D warnings` by editing `bootstrap.toml` to append the following:

```toml
[rust]
Expand Down Expand Up @@ -116,7 +116,7 @@ target = ["mipsisa64r6el-unknown-linux-gnuabi64"]

Make sure that `mipsisa64r6el-unknown-linux-gnuabi64-gcc` is available from your executable search path (`$PATH`).

Alternatively, you can specify the directories to all necessary toolchain executables in `config.toml`:
Alternatively, you can specify the directories to all necessary toolchain executables in `bootstrap.toml`:

```toml
[target.mipsisa64r6el-unknown-linux-gnuabi64]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/nto-qnx.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ For conditional compilation, following QNX specific attributes are defined:

## Building the target

1. Create a `config.toml`
1. Create a `bootstrap.toml`

Example content:

Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/nvptx64-nvidia-cuda.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ What format do binaries use by default? ELF, PE, something else?
## Building the target

If Rust doesn't build the target by default, how can users build it? Can users
just add it to the `target` list in `config.toml`?
just add it to the `target` list in `bootstrap.toml`?

## Building Rust programs

Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/openharmony.md
Original file line number Diff line number Diff line change
Expand Up @@ -145,7 +145,7 @@ linker = "/path/to/x86_64-unknown-linux-ohos-clang.sh"
## Building the target from source

Instead of using `rustup`, you can instead build a rust toolchain from source.
Create a `config.toml` with the following contents:
Create a `bootstrap.toml` with the following contents:

```toml
profile = "compiler"
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/pc-windows-gnullvm.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ Like with any other Windows target, created binaries are in PE format.

These targets can be easily cross-compiled
using [llvm-mingw](https://github.com/mstorsjo/llvm-mingw) toolchain or [MSYS2 CLANG*](https://www.msys2.org/docs/environments/) environments.
Just fill `[target.*]` sections for both build and resulting compiler and set installation prefix in `config.toml`.
Just fill `[target.*]` sections for both build and resulting compiler and set installation prefix in `bootstrap.toml`.
Then run `./x.py install`.
In my case I had ran `./x.py install --host x86_64-pc-windows-gnullvm --target x86_64-pc-windows-gnullvm` inside MSYS2 MINGW64 shell
so `x86_64-pc-windows-gnu` was my build toolchain.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ The target can be built by enabling it for a `rustc` build.
target = ["powerpc64le-unknown-linux-musl"]
```

Make sure your C compiler is included in `$PATH`, then add it to the `config.toml`:
Make sure your C compiler is included in `$PATH`, then add it to the `bootstrap.toml`:

```toml
[target.powerpc64le-unknown-linux-musl]
Expand Down
2 changes: 1 addition & 1 deletion src/doc/rustc/src/platform-support/redox.md
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ Redox OS binaries use ELF as file format.

## Building the target

You can build Rust with support for the targets by adding it to the `target` list in `config.toml`. In addition a copy of [relibc] needs to be present in the linker search path.
You can build Rust with support for the targets by adding it to the `target` list in `bootstrap.toml`. In addition a copy of [relibc] needs to be present in the linker search path.

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ Calling `extern "C"` on the target uses the C calling convention outlined in the
## Building for the zkVM

Programs for the zkVM could be built by adding it to the `target` list in
`config.toml`. However, we recommend building programs in our starter template
`bootstrap.toml`. However, we recommend building programs in our starter template
generated by the [cargo-risczero] utility and the [risc0-build] crate. This
crate calls `rustc` with `-C "link-arg=-Ttext=` so that it maps the text in the
appropriate location as well as generating variables that represent the ELF and
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ The target can be built by enabling it for a `rustc` build.
target = ["riscv32imac-unknown-xous-elf"]
```

Make sure your C compiler is included in `$PATH`, then add it to the `config.toml`:
Make sure your C compiler is included in `$PATH`, then add it to the `bootstrap.toml`:

```toml
[target.riscv32imac-unknown-xous-elf]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ These targets are distributed through `rustup`, and otherwise require no
special configuration.

If you need to build your own Rust for some reason though, the targets can be
enabled in `config.toml`. For example:
enabled in `bootstrap.toml`. For example:

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ The target can be built by enabling it for a `rustc` build.
target = ["riscv64gc-unknown-linux-musl"]
```

Make sure your C compiler is included in `$PATH`, then add it to the `config.toml`:
Make sure your C compiler is included in `$PATH`, then add it to the `bootstrap.toml`:

```toml
[target.riscv64gc-unknown-linux-musl]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ This target is distributed through `rustup`, and otherwise requires no
special configuration.

If you need to build your own Rust for some reason though, the target can be
enabled in `config.toml`. For example:
enabled in `bootstrap.toml`. For example:

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ Because it is Tier 3, Rust does not yet ship pre-compiled artifacts for this
target.

Therefore, you can build Rust with support for the target by adding it to the
target list in `config.toml`, a sample configuration is shown below.
target list in `bootstrap.toml`, a sample configuration is shown below.

```toml
[build]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ considerations for binary layout will require linker options or linker scripts.
## Building the target

You can build Rust with support for the target by adding it to the `target`
list in `config.toml`:
list in `bootstrap.toml`:

```toml
[build]
Expand Down
Loading