There are three main ways to increase the speed of compiling links:
1. Increase the number of threads used in Xcode compilation
Copy Code code as follows:
Defaults Write Com.apple.Xcode pbxnumberofparallelbuildsubtasks 4
Xcode is compiled by default using the same threads as CPU cores, but because the IO operations in the compilation process tend to be more than CPU operations, the appropriate number of elevated threads can speed up the compilation to some extent.
2. Change the debug information format to dwarf
In the build settings for target in the project, locate the debug Information format and change the dwarf with dSYM file at debug to dwarf.
This setting is whether to add debugging information to the executable file, after the dwarf, if the program crashes, you will not be able to output the crash location of the function stack, but because the debug mode can be in Xcode to view debugging information, so change to dwarf impact is not significant. After this change, you can significantly increase the speed of compilation.
3. Change build Active architecture to Yes
In the build settings corresponding to target in the project, find the item "Build Active Architecture" only, change debug to Yes.
This setting is to compile only the version of the current schema, and if no, all schema versions are compiled. It is important to note that this option must be yes in release mode, otherwise the published IPA will not run on some devices. After this change, you can significantly improve the compilation speed.
After setting the above three items, I believe that the compilation time will be shortened a lot.
The above mentioned is the entire content of this article, I hope you can enjoy.