Skip to content

Remove deprecated fields in bootstrap #143926

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions src/bootstrap/src/core/config/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -697,7 +697,7 @@ impl Config {
config.change_id = toml.change_id.inner;

let Build {
mut description,
description,
build,
host,
target,
Expand Down Expand Up @@ -749,7 +749,7 @@ impl Config {
compiletest_diff_tool,
compiletest_use_stage0_libtest,
tidy_extra_checks,
mut ccache,
ccache,
exclude,
} = toml.build.unwrap_or_default();

Expand Down Expand Up @@ -942,7 +942,7 @@ impl Config {
config.rust_profile_use = flags_rust_profile_use;
config.rust_profile_generate = flags_rust_profile_generate;

config.apply_rust_config(toml.rust, flags_warnings, &mut description);
config.apply_rust_config(toml.rust, flags_warnings);

config.reproducible_artifacts = flags_reproducible_artifact;
config.description = description;
Expand All @@ -963,7 +963,7 @@ impl Config {
config.channel = channel;
}

config.apply_llvm_config(toml.llvm, &mut ccache);
config.apply_llvm_config(toml.llvm);

config.apply_gcc_config(toml.gcc);

Expand Down
16 changes: 1 addition & 15 deletions src/bootstrap/src/core/config/toml/llvm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,6 @@ define_config! {
tests: Option<bool> = "tests",
enzyme: Option<bool> = "enzyme",
plugins: Option<bool> = "plugins",
// FIXME: Remove this field at Q2 2025, it has been replaced by build.ccache
ccache: Option<StringOrBool> = "ccache",
static_libstdcpp: Option<bool> = "static-libstdcpp",
libzstd: Option<bool> = "libzstd",
ninja: Option<bool> = "ninja",
Expand Down Expand Up @@ -97,7 +95,6 @@ pub fn check_incompatible_options_for_ci_llvm(
assertions: _,
tests: _,
plugins,
ccache: _,
static_libstdcpp: _,
libzstd,
ninja: _,
Expand Down Expand Up @@ -149,11 +146,7 @@ pub fn check_incompatible_options_for_ci_llvm(
}

impl Config {
pub fn apply_llvm_config(
&mut self,
toml_llvm: Option<Llvm>,
ccache: &mut Option<StringOrBool>,
) {
pub fn apply_llvm_config(&mut self, toml_llvm: Option<Llvm>) {
let mut llvm_tests = None;
let mut llvm_enzyme = None;
let mut llvm_offload = None;
Expand All @@ -168,7 +161,6 @@ impl Config {
tests,
enzyme,
plugins,
ccache: llvm_ccache,
static_libstdcpp,
libzstd,
ninja,
Expand All @@ -191,13 +183,7 @@ impl Config {
download_ci_llvm,
build_config,
} = llvm;
if llvm_ccache.is_some() {
eprintln!("Warning: llvm.ccache is deprecated. Use build.ccache instead.");
}

if ccache.is_none() {
*ccache = llvm_ccache;
}
set(&mut self.ninja_in_file, ninja);
llvm_tests = tests;
llvm_enzyme = enzyme;
Expand Down
20 changes: 1 addition & 19 deletions src/bootstrap/src/core/config/toml/rust.rs
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,6 @@ define_config! {
incremental: Option<bool> = "incremental",
default_linker: Option<String> = "default-linker",
channel: Option<String> = "channel",
// FIXME: Remove this field at Q2 2025, it has been replaced by build.description
description: Option<String> = "description",
musl_root: Option<String> = "musl-root",
rpath: Option<bool> = "rpath",
strip: Option<bool> = "strip",
Expand Down Expand Up @@ -320,7 +318,6 @@ pub fn check_incompatible_options_for_ci_rustc(
jemalloc,
rpath,
channel,
description,
default_linker,
std_features,

Expand Down Expand Up @@ -388,7 +385,6 @@ pub fn check_incompatible_options_for_ci_rustc(
err!(current_rust_config.std_features, std_features, "rust");

warn!(current_rust_config.channel, channel, "rust");
warn!(current_rust_config.description, description, "rust");

Ok(())
}
Expand All @@ -415,12 +411,7 @@ pub(crate) fn validate_codegen_backends(backends: Vec<String>, section: &str) ->
}

impl Config {
pub fn apply_rust_config(
&mut self,
toml_rust: Option<Rust>,
warnings: Warnings,
description: &mut Option<String>,
) {
pub fn apply_rust_config(&mut self, toml_rust: Option<Rust>, warnings: Warnings) {
let mut debug = None;
let mut rustc_debug_assertions = None;
let mut std_debug_assertions = None;
Expand Down Expand Up @@ -459,7 +450,6 @@ impl Config {
randomize_layout,
default_linker,
channel: _, // already handled above
description: rust_description,
musl_root,
rpath,
verbose_tests,
Expand Down Expand Up @@ -552,14 +542,6 @@ impl Config {
set(&mut self.jemalloc, jemalloc);
set(&mut self.test_compare_mode, test_compare_mode);
set(&mut self.backtrace, backtrace);
if rust_description.is_some() {
eprintln!(
"Warning: rust.description is deprecated. Use build.description instead."
);
}
if description.is_none() {
*description = rust_description;
}
set(&mut self.rust_dist_src, dist_src);
set(&mut self.verbose_tests, verbose_tests);
// in the case "false" is set explicitly, do not overwrite the command line args
Expand Down
5 changes: 5 additions & 0 deletions src/bootstrap/src/utils/change_tracker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -481,4 +481,9 @@ pub const CONFIG_CHANGE_HISTORY: &[ChangeInfo] = &[
severity: ChangeSeverity::Warning,
summary: "The current `./x suggest` implementation has been removed due to it being quite broken and a lack of maintenance bandwidth, with no prejudice against re-implementing it in a more maintainable form.",
},
ChangeInfo {
change_id: 143926,
severity: ChangeSeverity::Warning,
summary: "Removed `rust.description` and `llvm.ccache` as it was deprecated in #137723 and #136941 long time ago.",
},
];
Loading