[Solved] Xcode error: cycle inside*******; building could produce unreliable results.

Xcode Error: Cycle inside *******; building could produce unreliable results. This usually can be resolved by moving the target’s Headers build phase before Compile Sources.
Cycle details:


Showing All Issues
Cycle inside rtc_extension; building could produce unreliable results. This usually can be resolved by moving the target's Headers build phase before Compile Sources.
Cycle details:
→ Target 'rtc_extension' has copy command from '/Users/xxx/Documents/SourceCode/base_extension/xxx/third_party/mac/xxx_webrtc.framework' to '/Users/xxx/Documents/SourceCode/base_extension/xxx/bin/Release/xxx_webrtc.framework'
○ Target 'rtc_extension' has link command with output '/Users/xxx/Documents/SourceCode/base_extension/xxx/bin/Release/librtc_extension.dylib'
○ Target 'rtc_extension' has copy command from '/Users/xxx/Documents/SourceCode/base_extension/xxx/third_party/mac/TTTRtcSDK.framework' to '/Users/xxx/Documents/SourceCode/base_extension/xxx/bin/Release/TTTRtcSDK.framework'

Error reason:

Xcode 10 uses new build system by default, which is different from xcode9.

 

Solution:

Modify build system
in Xcode menu bar – >File -> Progect setting, modify the build system to legacy build system, and then clean and compile.

Read More: