-
Notifications
You must be signed in to change notification settings - Fork 510
fix: handle guest programs that depends on ring #2185
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
Conversation
Can you fix the diff in sp1up pls |
@nhtyy Done |
d8902b4
to
1126234
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add some documentation for the purpose of the -D__ILP32___
flag for future dev?
Otherwise, LGTM.
1126234
to
88993f3
Compare
@leruaa When I update sp1 from 4.1.7 to 4.2.0, the ring dep fails to compile unfortunately. Removing The error message from our CI (a private repo):
|
The error doesn't remind me of anything. What did you remove exaclty to make it work? |
Removing the env diff --git a/crates/build/src/command/local.rs b/crates/build/src/command/local.rs
index 62230fa7..7813d6eb 100644
--- a/crates/build/src/command/local.rs
+++ b/crates/build/src/command/local.rs
@@ -29,7 +29,7 @@ pub(crate) fn create_local_command(
// the following flag is added to avoid build failure on ring:
// https://github.com/briansmith/ring/blob/bcf68dd27a071ff1947b6327d4c6bde526e24b60/include/ring-core/target.h#L47
- command.env("CFLAGS", "-D__ILP32__");
+ // command.env("CFLAGS", "-D__ILP32__");
let parsed_version = {
let output = Command::new("rustc") |
On what machine run your CI? |
You mean OS? It's ubuntu-24.04. |
Hey @leruaa, any update here? Should I create a dedicated issue for this? |
Yes please, it will be easier to track |
Motivation
Until now it wasn't possible to build programs that depends on
ring
. Linking is failing with:Solution
I've been able to successfully build a program by doing the following:
2024.01.05
versionCFLAGS=-D__ILP32__
tocargo build
to avoid this errorPR Checklist