MergeSwiftModule - Building a Swift app in Xcode 6.3 gets stuck in "Merge MyApp.swiftmodule"
Asked Answered
T

1

4

Building an app in Xcode 6.3 gets stuck for several minutes (approx. 10mins) on a step Merge MyApp.swiftmodule:

MergeSwiftModule normal x86_64 /Users/.../Library/Developer/Xcode/DerivedData/MyApp-crbdsfrhkvpiynaffvhzzsspiels/Build/Intermediates/MyApp.build/Debug-iphonesimulator/MyApp.build/Objects-normal/x86_64/MyApp.swiftmodule

this wasn't an issue in previous version of Xcode 6.2 and Swift 1.0.

Titrate answered 21/4, 2015 at 8:53 Comment(2)
Delete 'Derived Data', 'Reset your Simulator' and 'Clean Project'. These are the most common things and will solve your problem too.Faenza
That unfortunately doesn't help.Titrate
T
16

Enabling SWIFT_WHOLE_MODULE_OPTIMIZATION for the target seems to fix this issue.

Enabling swift whole module optimization in Xcode build settings

Source: https://devforums.apple.com/message/1119343#1119343

Titrate answered 21/4, 2015 at 11:2 Comment(1)
Option can be found under "Swift Compiler - Code Generation" on the Build Settings tab of your target. Thanks so much for sharing the fix!Nightshirt

© 2022 - 2024 — McMap. All rights reserved.