kodika / MutataApp

49 stars 9 forks source link

Swift error: no such module 'PackageDescription' #9

Closed neerajbaid closed 1 year ago

neerajbaid commented 2 years ago
Swift PM flags: --configuration debug -Xswiftc -DDEBUG -Xswiftc -Xfrontend -Xswiftc -suppress-warnings
/Users/neeraj/Development/Atlantic/MutataApp/build/AndroidProject/app/src/main/swift: error: manifest parse error(s):
/Users/neeraj/Development/Atlantic/MutataApp/build/AndroidProject/app/src/main/swift/Package.swift:2:8: error: no such module 'PackageDescription'
import PackageDescription
       ^

FAILURE: Build failed with an exception.

I'm attempting to prepare the demo app "Mutata-Showcase-App" but I'm getting this error when running ./scripts/20-InstallAndRun.sh

I am using the swift 5.4.2 toolchain as instructed:

Apple Swift version 5.4.2 (swift-5.4.2-RELEASE)
Target: x86_64-apple-darwin21.5.0

Any help would be greatly appreciated! Thanks so much.

kostassite commented 1 year ago

Hi, Latest version of MutataApp should fix the problem. The problem was that you were probably using a Xcode version greater than 12.4, which didn't have correct swift toolchain inside and newer versions of macOS were not using the provided toolchain but are defaulting to the Xcode one.

Just delete the folder and redo the steps and it should work!