Skip to content

Commit

Permalink
Fix rustc_target test: wasmNN-none should support dynamic linking
Browse files Browse the repository at this point in the history
  • Loading branch information
graydon committed Oct 23, 2024
1 parent 212d516 commit 3ba8749
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion compiler/rustc_target/src/spec/tests/tests_impl.rs
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,13 @@ impl Target {
// Check dynamic linking stuff
// BPF: when targeting user space vms (like rbpf), those can load dynamic libraries.
// hexagon: when targeting QuRT, that OS can load dynamic libraries.
if self.os == "none" && (self.arch != "bpf" && self.arch != "hexagon") {
// wasm{32,64}: dynamic linking is inherent in the definition of the VM.
if self.os == "none"
&& (self.arch != "bpf"
&& self.arch != "hexagon"
&& self.arch != "wasm32"
&& self.arch != "wasm64")
{
assert!(!self.dynamic_linking);
}
if self.only_cdylib
Expand Down

0 comments on commit 3ba8749

Please sign in to comment.