Xcode 6.3 always does full rebuild of Swift project
Asked Answered
T

2

11

One of the long anticipated features of Swift 1.2/Xcode 6.3 is incremental builds. They worked fine for me until recently, but now almost every time I change even a single line of code it does full rebuild.

I tried restarting Xcode, computer, cleaning derived data, but to no avail. Googling doesn't seem to reveal anything.

Does anyone else have this problem? How do I fix it?

Tound answered 16/4, 2015 at 11:49 Comment(0)
C
7

I think that this is what you searching for enter image description here

Cothurnus answered 16/4, 2015 at 11:56 Comment(2)
If you look at the release notes for 6.3.2 you'll see a note as to why turning on WMO might have improved things for you, also that you might want to try turning it off since they fixed it 6.3.2. developer.apple.com/library/ios/releasenotes/DeveloperTools/…Oligoclase
Still happening to me in 6.3.2 and turning on WMO solved the problem.Phrixus
E
2

I am not this is a source of the problem. According to https://developer.apple.com

Swift Performance

A new compilation mode has been introduced for Swift called Whole Module Optimization. This option optimizes all of the files in a target together and enables better performance (at the cost of increased compile time). The new flag can be enabled in Xcode using the “Whole Module Optimization” build setting or by using the swiftc command line tool with the flag -whole-module-optimization. (18603795)

Englishman answered 16/4, 2015 at 12:16 Comment(1)
yeah, this might not be the root cause, yet somehow it helped me.Tound

© 2022 - 2024 — McMap. All rights reserved.