Skip to content
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 link-native-libraries check for emscripten target #1724

Merged
merged 2 commits into from
Aug 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion src/compile.rs
Original file line number Diff line number Diff line change
Expand Up @@ -238,7 +238,11 @@ fn compile_target(
}
} else if target.is_emscripten() {
// Allow user to override these default flags
if !rustflags.flags.iter().any(|f| f == "link-native-libraries") {
if !rustflags
.flags
.iter()
.any(|f| f.contains("link-native-libraries"))
{
debug!("Setting `-Z link-native-libraries=no` for Emscripten");
rustflags.push("-Z");
rustflags.push("link-native-libraries=no");
Expand Down
2 changes: 1 addition & 1 deletion src/upload.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ impl PublishOpt {

/// Set to non interactive mode if we're running on CI
pub fn non_interactive_on_ci(&mut self) {
if env::var("CI").map(|v| v == "true").unwrap_or_default() {
if !self.non_interactive && env::var("CI").map(|v| v == "true").unwrap_or_default() {
eprintln!("🎛️ Running in non-interactive mode on CI");
self.non_interactive = true;
}
Expand Down