Skip to content

Commit

Permalink
fixup! Clean up wireguard-go-rs build script
Browse files Browse the repository at this point in the history
  • Loading branch information
dlon committed Jan 16, 2025
1 parent 8346735 commit 52bf987
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions wireguard-go-rs/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -400,17 +400,14 @@ fn generate_exports_def(exports_path: impl AsRef<Path>) -> anyhow::Result<()> {
writeln!(file, "LIBRARY libwg").context("Write LIBRARY statement")?;
writeln!(file, "EXPORTS").context("Write EXPORTS statement")?;

let mut libwg_exports = vec![];
for path in &[
"./libwg/libwg.go",
"./libwg/libwg_windows.go",
"./libwg/libwg_daita.go",
] {
libwg_exports.extend(gather_exports(path).context("Failed to find exports")?);
}

for export in libwg_exports {
writeln!(file, "\t{export}").context("Failed to output exported function")?;
for export in gather_exports(path).context("Failed to find exports")? {
writeln!(file, "\t{export}").context("Failed to output exported function")?;
}
}

Ok(())
Expand Down

0 comments on commit 52bf987

Please sign in to comment.