Skip to content

Commit 377112c

Browse files
authored
Patch for borken arm64 builds (#437)
1 parent bedf440 commit 377112c

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

rust/krb5-sys/build.rs

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,16 @@ fn main() {
2020
.allowlist_var("KRB5_.*")
2121
.allowlist_var("KADM5_.*")
2222
.allowlist_var("ENCTYPE_.*")
23+
// Variadic functions generate bindings that rustc on ARM64 considers FFI-unsafe.
24+
// We don't actually use them, so we can just blocklist the types, and any function
25+
// variants that use them.
26+
.blocklist_type("va_list")
27+
.blocklist_type("__builtin_va_list")
28+
.blocklist_type("__va_list_tag")
29+
.blocklist_function(".*_vset_.*")
30+
.blocklist_function(".*_vwrap_.*")
31+
.blocklist_function(".*_vprepend_.*")
32+
.blocklist_function(".*_va")
2333
.new_type_alias("krb5_error_code")
2434
.new_type_alias("kadm5_ret_t")
2535
.must_use_type("krb5_error_code")

0 commit comments

Comments
 (0)