mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-15 16:25:05 +00:00
Fix wasm host_dest name generation
This commit is contained in:
parent
c0b065b51a
commit
04e3ac37f4
1 changed files with 12 additions and 7 deletions
|
@ -613,13 +613,18 @@ pub fn rebuild_host(
|
||||||
roc_target::OperatingSystem::Wasi => "",
|
roc_target::OperatingSystem::Wasi => "",
|
||||||
};
|
};
|
||||||
|
|
||||||
let host_dest =
|
let host_dest = if matches!(target.architecture, Architecture::Wasm32) {
|
||||||
if shared_lib_path.is_none() || matches!(target.architecture, Architecture::Wasm32) {
|
if matches!(opt_level, OptLevel::Development) {
|
||||||
host_input_path.with_file_name(legacy_host_filename(target, opt_level).unwrap())
|
host_input_path.with_extension("o")
|
||||||
} else {
|
} else {
|
||||||
|
host_input_path.with_extension("bc")
|
||||||
|
}
|
||||||
|
} else if shared_lib_path.is_some() {
|
||||||
host_input_path
|
host_input_path
|
||||||
.with_file_name("dynhost")
|
.with_file_name("dynhost")
|
||||||
.with_extension(executable_extension)
|
.with_extension(executable_extension)
|
||||||
|
} else {
|
||||||
|
host_input_path.with_file_name(legacy_host_filename(target, opt_level).unwrap())
|
||||||
};
|
};
|
||||||
|
|
||||||
let env_path = env::var("PATH").unwrap_or_else(|_| "".to_string());
|
let env_path = env::var("PATH").unwrap_or_else(|_| "".to_string());
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue