Skip to content

Commit

Permalink
Update how wasm-component-ld is built
Browse files Browse the repository at this point in the history
Reuse preexisting macro and switch it to a "bootstrap tool" to try to
resolve build issues.
  • Loading branch information
alexcrichton committed Jul 9, 2024
1 parent 674267e commit 824002b
Showing 1 changed file with 1 addition and 28 deletions.
29 changes: 1 addition & 28 deletions src/bootstrap/src/core/build_steps/tool.rs
Original file line number Diff line number Diff line change
Expand Up @@ -329,6 +329,7 @@ bootstrap_tool!(
GenerateWindowsSys, "src/tools/generate-windows-sys", "generate-windows-sys";
RustdocGUITest, "src/tools/rustdoc-gui-test", "rustdoc-gui-test", is_unstable_tool = true, allow_features = "test";
CoverageDump, "src/tools/coverage-dump", "coverage-dump";
WasmComponentLd, "src/tools/wasm-component-ld", "wasm-component-ld";
);

#[derive(Debug, Clone, Hash, PartialEq, Eq)]
Expand Down Expand Up @@ -696,34 +697,6 @@ impl Step for LldWrapper {
}
}

#[derive(Debug, Clone, Hash, PartialEq, Eq)]
pub struct WasmComponentLd {
pub compiler: Compiler,
pub target: TargetSelection,
}

impl Step for WasmComponentLd {
type Output = PathBuf;

fn should_run(run: ShouldRun<'_>) -> ShouldRun<'_> {
run.never()
}

fn run(self, builder: &Builder<'_>) -> PathBuf {
builder.ensure(ToolBuild {
compiler: self.compiler,
target: self.target,
tool: "wasm-component-ld",
mode: Mode::ToolStd,
path: "src/tools/wasm-component-ld",
source_type: SourceType::InTree,
extra_features: Vec::new(),
allow_features: "",
cargo_args: Vec::new(),
})
}
}

#[derive(Debug, Clone, Hash, PartialEq, Eq)]
pub struct RustAnalyzer {
pub compiler: Compiler,
Expand Down

0 comments on commit 824002b

Please sign in to comment.