-
Notifications
You must be signed in to change notification settings - Fork 87
Description
Hi,
I’m trying to build Stack Wallet for the iOS Simulator on an Apple M4 machine, but I’m running into linker issues. I attempted to modify the iOS build scripts to support the simulator:
In flutter_libepiccash/scripts/ios/build_all.sh and flutter_libmwc/scripts/ios/build_all.sh, I changed:
rustup target add aarch64-apple-ios x86_64-apple-ios
to
rustup target add aarch64-apple-ios x86_64-apple-ios aarch64-apple-ios-sim
Modified the cargo lipo command:
cargo lipo --release
to
cargo lipo --release --targets aarch64-apple-ios-sim
Changed the library copy step:
cp target/aarch64-apple-ios/release/libmwc_wallet.a ${libs}
to
cp target/aarch64-apple-ios-sim/release/libmwc_wallet.a ${libs}
With these changes, the compilation of libmwc_wallet.a succeeded. However, I’m stuck at the final linking step:
error: Building for 'iOS-simulator', but linking in dylib
(/Users/.../.pub-cache/hosted/pub.dev/cs_monero_flutter_libs_ios-1.1.1/ios/Frameworks/MoneroWallet.framework/MoneroWallet) built for 'iOS'
Linker command failed with exit code 1 (use -v to see invocation)
It looks like cs_monero_flutter_libs_ios only contains arm64 slices for iOS, so linking fails for the simulator. I have already tried both x86_64 and arm64 (Apple M4) simulator architectures, but both failed.
Questions:
Does Stack Wallet support running on iOS Simulator?
If yes, what iOS Simulator versions and architectures are supported?
Are there any known workarounds to link cs_monero_flutter_libs_ios for the simulator?
Thank you for any guidance!