Closed jonblatho closed 6 years ago
As suggested in #102, this was solved by deleting the CommonCrypto directory.
@jonblatho ,
If we delete CommonCrypto, then how to use it. Can you please provide the solution.
@jonblatho There's no CommonCrypto directory under Pods/JSONWebToken. Which directory do you mean?
I have same issue
@nagarajaghantasala With Xcode 10/Swift 4.2, CommonCrypto is exposed natively as part of Swift (for Apple platforms only), rendering the included modulemap unnecessary and causing a name collision. Removing the modulemap solves the collision.
@Ast3r10n I can't reproduce that. I just pulled the JWT pod into a fresh project and the CommonCrypto directory is located under Pods/JSONWebToken:
The Podfile used:
# Uncomment the next line to define a global platform for your project
platform :ios, '10.0'
target 'JWT-test' do
# Comment the next line if you're not using Swift and don't want to use dynamic frameworks
use_frameworks!
# Pods for JWT-test
pod 'JSONWebToken'
target 'JWT-testTests' do
inherit! :search_paths
# Pods for testing
end
target 'JWT-testUITests' do
inherit! :search_paths
# Pods for testing
end
end
@EdwardSun123 Not sure which issue exactly you’re referring to, but hopefully some of the above information helps. Some PRs in this repo also offer more permanent solutions to the issue.
I looked for the CommonCrypto directory but it just isn't there. I have found a solution, though, as stated here.
EDIT: I was looking in the wrong place. The directory is there, but I still find it easier to just remove the redeclaration.
In my case I connect an actual iphone not simulator and run the app once on it, It solved the problem. But connect iphone firstly, then choose it from the menu of simulators, then press run button. The problem will solve too.
Running on real device showed me the exact error. Thanks @GergesEid
You may have another reason causing this error. Regards. You are welcome @ergunkocak
The following build error occurs in Xcode 10 beta:
Here is the full invocation:
This occurs in the JSONWebToken project when using CocoaPods. No further information is provided.
The package does compile:
$ swift build
(with a warning for accessingString.characters
)The package does not compile:
Same error both times.