Skip to content

Commit

Permalink
Generate bindings only after successful builds
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniusnaumann committed Oct 1, 2023
1 parent 7516248 commit 05fab5f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
[package]
name = "cargo-swift"
description = "A cargo plugin to easily build Swift packages from Rust code for use in iOS and macOS applications"
version = "0.4.0"
version = "0.4.1-alpha"
edition = "2021"
authors = ["Antonius Naumann <[email protected]>"]
license = "MIT OR Apache-2.0"
Expand Down
4 changes: 2 additions & 2 deletions src/commands/package.rs
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,12 @@ pub fn run(
}
}

let namespace = generate_bindings_with_output(&config)?;

for target in &targets {
build_with_output(target, &lib_name, mode, lib_type, &config)?;
}

let namespace = generate_bindings_with_output(&config)?;

recreate_output_dir(&package_name).expect("Could not create package output directory!");
create_xcframework_with_output(&targets, &lib_name, &package_name, mode, lib_type, &config)?;
create_package_with_output(&package_name, &namespace, &config)?;
Expand Down

0 comments on commit 05fab5f

Please sign in to comment.