-
Notifications
You must be signed in to change notification settings - Fork 10
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
Build fails when using non-external library #23
Comments
We haven't tested this on iOS before, maybe MoltenVK needs to be built with some additional flags to compile properly on iOS? |
I looked at this a bit more. Cloning the repo and just trying to build it for macos (cargo build) is failing for me. It could be due to upstream changes, or maybe Xcode version differences. I'm not familiar enough with either one to know for sure, but I will guess Xcode versions :) I have two different machines failing the build with different errors. The one with most recent Xcode and building for macOS results in
Building x86_64-apple-ios (simulator) or aarch64-apple-ios results in
Maybe iOS requires different frameworks? Some other notes:
I don't think any of these issues are impossible to solve, but they may require a decent amount of ongoing maintenance to keep up with upstream changes. There's also a surprising number of usage scenarios (3 rust targets, multiple device families, multiple build paths depending on what's installed) I suspect that for the time being automatically building moltenvk is going to be more fragile than building MoltenVK myself. At the least, it's easier to get feedback and troubleshoot when it building MoltenVK does fail. |
Oh just a heads up, "fat" libraries might not be possible to use with rust right now :/ |
Ouch does sound somewhat complex, but good investigations! Ideally we've been wanting to try out using gfx-portability instead of MoltenVK, which is a smaller and much faster to build code base (and in Rust!), but we haven't tried it out yet. Both @MaikKlein and I are also both out on vacation right now. Could potentially be an option here instead of further deeper work on MoltenVK, but likely will have its own issues and challenges, though less likely around build systems. |
I'm trying to get vulkan, rust, and SDL2 up and running on iOS. I created an empty rust project to build as a staticlib. I added a dependency for ash-molten (not using the
external
feature). My lib.rs has a #[no_mangle] extern "C" function which my Xcode project calls. I am largely following the steps here: https://github.com/thombles/dw2019rust/tree/master/modulesWhen I trigger a build, I get this error:
It looks like the spirv-tools are failing to build because they use std::system in the code which is not available in iOS. I'm not sure what to do here... is this code that would end up on device? Maybe this is an upstream change that recently broke this?
The text was updated successfully, but these errors were encountered: