Skip to content

Commit d293fcb

Browse files
Rollup merge of rust-lang#67351 - Mark-Simulacrum:always-channel, r=pietroalbini
Set release channel on non-dist builders Toolstate publication only runs if the channel is "nightly" and previously the toolstate builders did not know that the channel was nightly (since they are not dist builders). A look through bootstrap seems to indicate that nothing should directly depend on the channel being set to `-dev` on the test builders, though this may cause some problems with UI tests (if for some reason they're dumping the channel into stderr), but we cannot find evidence of such so hopefully this is fine. r? @pietroalbini
2 parents 0de96d3 + cbd1e73 commit d293fcb

File tree

2 files changed

+9
-4
lines changed

2 files changed

+9
-4
lines changed

src/bootstrap/toolstate.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ use std::env;
1313
// Each cycle is 42 days long (6 weeks); the last week is 35..=42 then.
1414
const BETA_WEEK_START: u64 = 35;
1515

16-
#[cfg(linux)]
16+
#[cfg(target_os = "linux")]
1717
const OS: Option<&str> = Some("linux");
1818

1919
#[cfg(windows)]
2020
const OS: Option<&str> = Some("windows");
2121

22-
#[cfg(all(not(linux), not(windows)))]
22+
#[cfg(all(not(target_os = "linux"), not(windows)))]
2323
const OS: Option<&str> = None;
2424

2525
type ToolstateData = HashMap<Box<str>, ToolState>;
@@ -379,7 +379,7 @@ fn change_toolstate(
379379
let mut regressed = false;
380380
for repo_state in old_toolstate {
381381
let tool = &repo_state.tool;
382-
let state = if cfg!(linux) {
382+
let state = if cfg!(target_os = "linux") {
383383
&repo_state.linux
384384
} else if cfg!(windows) {
385385
&repo_state.windows

src/ci/run.sh

+6-1
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,13 @@ fi
4444
# FIXME: need a scheme for changing this `nightly` value to `beta` and `stable`
4545
# either automatically or manually.
4646
export RUST_RELEASE_CHANNEL=nightly
47+
48+
# Always set the release channel for bootstrap; this is normally not important (i.e., only dist
49+
# builds would seem to matter) but in practice bootstrap wants to know whether we're targeting
50+
# master, beta, or stable with a build to determine whether to run some checks (notably toolstate).
51+
RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --release-channel=$RUST_RELEASE_CHANNEL"
52+
4753
if [ "$DEPLOY$DEPLOY_ALT" = "1" ]; then
48-
RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --release-channel=$RUST_RELEASE_CHANNEL"
4954
RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --enable-llvm-static-stdcpp"
5055
RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --set rust.remap-debuginfo"
5156
RUST_CONFIGURE_ARGS="$RUST_CONFIGURE_ARGS --debuginfo-level-std=1"

0 commit comments

Comments
 (0)