问题
I hit the error on below on Xcode 8, can everyone help to solve it. My application need to support iOS 8 and above.
Alamofire will not be code signed because its settings don't specify a development team. “Use Legacy Swift Language Version” (SWIFT_VERSION) is required to be configured correctly for targets which use Swift. Use the [Edit > Convert > To Current Swift Syntax…] menu to choose a Swift version or use the Build Settings editor to configure the build setting directly.
Thanks
回答1:
What did it for me with the updated Alamofire and Xcode 8 is the following:
1) Open your project via the <yourproject>.xcworkspace
file
2) Go to Pods -> Targets -> Alamofire -> Build Settings and set the following property:
I think it has to do with the fact that the new Alamofire 4.0 was a pretty big update due to Swift 3/Xcode 8. I haven't had the error before updating.
PS The first part "Alamofire will not be code signed because its settings don't specify a development team." of your error message seemed like a separate thing in my case, which either got solved because I did pod install
a few times until Alamofire actually got updated or because of the setting that I mentioned above. Either way both things cleared out for me.
回答2:
Add this to the end of your Podfile to set the build configurations for each pod to use the latest version of Swift:
post_install do |installer|
installer.pods_project.targets.each do |target|
target.build_configurations.each do |config|
config.build_settings['SWIFT_VERSION'] = '3.0'
end
end
end
来源:https://stackoverflow.com/questions/39485577/alamofire-not-be-code-signed-because-its-settings-dont-specify-a-development