windows build fix

This commit is contained in:
John Smith 2023-09-16 13:07:12 -04:00 committed by Christien Rioux
parent ad47e400ed
commit 177bccbe12

View File

@ -27,18 +27,18 @@ fn get_desired_capnp_version_string() -> String {
}
fn get_capnp_version_string() -> String {
let output = Command::new("capnpc")
let output = Command::new("capnp")
.arg("--version")
.stdout(Stdio::piped())
.output()
.expect("capnpc was not in the PATH");
.expect("capnp was not in the PATH");
let s = String::from_utf8(output.stdout)
.expect("'capnpc --version' output was not a valid string")
.expect("'capnp --version' output was not a valid string")
.trim()
.to_owned();
if !s.starts_with("Cap'n Proto version ") {
panic!("invalid capnpc version string: {}", s);
panic!("invalid capnp version string: {}", s);
}
s[20..].to_owned()
}