Skip to content
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: 4 additions & 2 deletions build_system/abi_cafe.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ use crate::{CodegenBackend, SysrootKind, build_sysroot};
static ABI_CAFE_REPO: GitRepo = GitRepo::github(
"Gankra",
"abi-cafe",
"f1220cfd13b57f5c0082c26529163865ee25e115",
"fe93a9acd461425d",
"49efdca14e9d48c34e50552d1f620615a87637bb",
"21fed1b4ca4cd439",
"abi-cafe",
);

Expand Down Expand Up @@ -46,6 +46,8 @@ pub(crate) fn run(
let mut cmd = ABI_CAFE.run(bootstrap_host_compiler, dirs);
cmd.arg("--");

cmd.arg("--rules").arg(dirs.source_dir.join("scripts/abi-cafe-rules.toml"));

// stdcall, vectorcall and such don't work yet
cmd.arg("--conventions").arg("c").arg("--conventions").arg("rust");

Expand Down
69 changes: 0 additions & 69 deletions patches/0002-abi-cafe-Disable-broken-tests.patch

This file was deleted.

24 changes: 24 additions & 0 deletions patches/0002-abi-cafe-Enable-debuginfo.patch
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This patch is for Gankra/abi-cafe#72.

Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
From 236df390f3bc4ed69c26f4d51d584bea246da886 Mon Sep 17 00:00:00 2001
From: bjorn3 <[email protected]>
Date: Tue, 9 Jul 2024 11:25:14 +0000
Subject: [PATCH] Enable debuginfo

---
src/toolchains/rust.rs | 1 +
1 file changed, 1 insertions(+)

diff --git a/src/toolchains/rust.rs b/src/toolchains/rust.rs
index 0c50f7a..bfde2b1 100644
--- a/src/toolchains/rust.rs
+++ b/src/toolchains/rust.rs
@@ -83,6 +83,7 @@ impl Toolchain for RustcToolchain {
.arg(out_dir)
.arg("--target")
.arg(&self.platform_info.target)
+ .arg("-g")
.arg(format!("-Cmetadata={lib_name}"))
.arg(src_path);
if let Some(codegen_backend) = &self.codegen_backend {
--
2.34.1

17 changes: 17 additions & 0 deletions scripts/abi-cafe-rules.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[target.'cfg(all(target_arch = "aarch64", target_os = "linux"))']
'F32Array::conv_c'.busted = "check"

[target.'cfg(all(target_arch = "aarch64", target_os = "macos"))']
'SingleVariantUnion::conv_c::repr_c'.busted = "check"
'OptionU128::conv_rust::repr_c::rustc_caller'.busted = "run"
'OptionU128::conv_rust::repr_c::cgclif_caller'.busted = "check"
Comment on lines +4 to +7
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ooh nice


[target.'cfg(all(target_arch = "x86_64", windows))']
'simple::conv_rust'.busted = "check"
'simple::conv_rust::rustc_caller'.busted = "run"

[target.'*'.'f16']
run = "skip"

[target.'*'.'f128']
run = "skip"