-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix querying emcc on windows #4248
base: main
Are you sure you want to change the base?
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @tgross35 (or someone else) some time within the next two weeks. Please see the contribution instructions for more information. Namely, in order to ensure the minimum review times lag, PR authors and assigned reviewers should ensure that the review label (
|
build.rs
Outdated
#[cfg(target_os = "windows")] | ||
let output = Command::new("emcc.bat").arg("-dumpversion").output().ok()?; | ||
|
||
#[cfg(not(target_os = "windows"))] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: could you use if cfg!(target_os = "windows") { ... }
here instead? cfg!(...)
is slightly preferred over #[cfg(...)]
where possible since it allows the code to be checked on all OSs.
Otherwise lgtm, please squash with the change.
Fyi @hoodmane.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Applied this
Could this go on 0.2 as well once it's merged? |
Cc @messense maybe we want this change in maturin too? |
Done in PyO3/maturin#2478 |
Fyi anyone can add the label, it's just @rustbot label +stable-nominated |
Looks like this needs a rebase, could you do that? |
@rustbot author for the rebase |
Pretty minor change, just queries emcc.bat since
emcc
will not work on windowsFor example this simple script will output this on windows