mirror of
https://github.com/roc-lang/roc.git
synced 2024-09-11 18:58:24 +03:00
fixed ld warning
This commit is contained in:
parent
1c80b0db7d
commit
03f76dfa37
@ -811,7 +811,7 @@ fn link_macos(
|
||||
"-arch",
|
||||
&arch,
|
||||
"-macos_version_min",
|
||||
"10.15",
|
||||
&get_macos_version(),
|
||||
])
|
||||
.args(input_paths);
|
||||
|
||||
@ -852,6 +852,23 @@ fn link_macos(
|
||||
}
|
||||
}
|
||||
|
||||
fn get_macos_version() -> String {
|
||||
let cmd_stdout = Command::new("sw_vers")
|
||||
.arg("-productVersion")
|
||||
.output()
|
||||
.expect("Failed to execute command 'sw_vers -productVersion'")
|
||||
.stdout;
|
||||
|
||||
let full_version_string = String::from_utf8(cmd_stdout)
|
||||
.expect("Failed to convert output of command 'sw_vers -productVersion' into a utf8 string");
|
||||
|
||||
full_version_string
|
||||
.split('.')
|
||||
.take(2)
|
||||
.collect::<Vec<&str>>()
|
||||
.join(".")
|
||||
}
|
||||
|
||||
fn link_wasm32(
|
||||
_target: &Triple,
|
||||
output_path: PathBuf,
|
||||
|
Loading…
Reference in New Issue
Block a user