swiftsocket / SwiftSocket

The easy way to use sockets on Apple platforms
BSD 3-Clause "New" or "Revised" License
1.68k stars 400 forks source link

Build for macOSX error: SWIFT_VERSION '3.0' is unsupported #199

Open donly opened 4 years ago

donly commented 4 years ago

Build env: Xcode 11.5, macOS Catalina 10.15.5, error details below. Build with Carthage: carthage update --platform ios,macosx

error: SWIFT_VERSION '3.0' is unsupported, supported versions are: 4.0, 4.2, 5.0. (in target 'SwiftSocket macOS' from project 'SwiftSocket')

When I change Swift Language Version to Swift 4, it can build without error.

it seems relate to this https://github.com/swiftsocket/SwiftSocket/issues/174

ghost commented 4 years ago

I faced this issue as well as you. In my case, changing Swift version from 5 to 4 did not clear this error.

zx5000 commented 3 years ago

This project is dead now due to Apple's genius move of not-backward-compatible modus? So somewhere in the universe there is an old Xcode waiting to convert your Swift3 to 4. Your mission is to seek the guru who knows where this mythical creature lies.

AZOM commented 3 years ago

I fixed this once like this:

` # The easy way to use sockets on Apple platforms - https://github.com/swiftsocket/SwiftSocket

Temporary solution because of using still Swift 3 in pod 2.0.2, see https://github.com/swiftsocket/SwiftSocket/pull/186

pod 'SwiftSocket', :git => 'https://github.com/swiftsocket/SwiftSocket.git', :branch => 'master'`

Haibo-Zhou commented 3 years ago

I meet the same issue, changing Swift version from 3.x to 5.x fix it.

iOS 14, Xcode 12.

antiero commented 3 years ago

@Haibo-Zhou 's steps worked for me too. I had a job finding where Swift version was! It can be found here:

Pods > TARGETS > SwiftSocket > Swift Compiler - Language

image