OpenFlutter / tobias

AliPay For Flutter.支付宝Flutter插件
Apache License 2.0
695 stars 116 forks source link

添加此依赖后ios模拟器debug编译不成功 #107

Closed bdw9005 closed 3 years ago

bdw9005 commented 3 years ago

iphone8模拟器,ios11.4 ,flutter版本 2.5.0, tobias: ^2.1.2+1,开发工具:android studio 2020,xcode12.4 Launching lib/main.dart on iPhone 8 in debug mode... Running Xcode build... Xcode build done. 23.4s Failed to build iOS app Error output from Xcode build: ↳ BUILD FAILED

Xcode's output: ↳ ld: building for iOS Simulator, but linking in object file built for iOS, file '/Users/xxxx/Documents/workspace/flutter/xxx__flutter/ios/Pods/AlipaySDK-iOS/AlipaySDK.framework/AlipaySDK' for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation) note: Using new build system note: Building targets in parallel note: Planning build note: Constructing build description

Could not build the application for the simulator. Error launching application on iPhone 8.

cipchk commented 3 years ago

@JarvanMo 升级至 Flutter 2.5 的时候;相同情况,相同环境,能否提供一下解决办法?

shenhuaxiyuan commented 3 years ago

遇到了同样的情况,flutter升级完2.5项目就跑不起来了

shenhuaxiyuan commented 3 years ago

找到解决办法了。Build Setting Excluded Architecture 加上 arm64

bdw9005 commented 3 years ago

找到解决办法了。Build Setting Excluded Architecture 加上 arm64 有试过这个方法,我这里仍不可用

cipchk commented 3 years ago

@bdw9005 确保 project.pbxproj 里面有:EXCLUDED_ARCHS = "arm64 i386";

bdw9005 commented 3 years ago

@bdw9005 确保 project.pbxproj 里面有:EXCLUDED_ARCHS = "arm64 i386"; 替换后可以了,很感谢,我完善下具体路径,可供其他人参考,ios/Runner.xcodeproj/project.pbxproj搜索EXCLUDED_ARCHS并将其修改为EXCLUDED_ARCHS = "arm64 i386";