Compiler error regarding CFNetwork after updating to XCode 10

Hi,


I updated to Xcode 10Gm from 9.4.1 and now my iOS project won't compile. Getting this nearly immediately:


ld: file not found: /System/Library/Frameworks/CoreServices.framework/Versions/A/Frameworks/CFNetwork.framework/Versions/A/CFNetwork for architecture x86_64


The thing is that CFNetwork is not within CoreServices, it's it own folder under System/Library. I am not including CoreServices in my project or referencing it anywhere in the code or settings. I deleted my build folder, derived data, and it still happens.


Any ideas why?

Accepted Reply

Not sure why or how, but I tried again and now its compiling fine. The only change was that I had compiled the project a few times under Xcode 9.x in between. So will mark this as solved- thanks for the help everyone!

Replies

Have you tried adding Core Services to the list of frameworks to see if the appliation builds properly?

Hi,


Yes, I tried adding both CoreServices and MobileCoreServices but it didn't help.

Hi, look at the WWDC about networking , apple deliever new framework for that. The thing is that they want us to move out from CFNetwork, it will not exist in future

Thanks for the reply- just checked it out. It was announced as a discouraged API but not even deprecated at this point, so it should still compile.

Not sure why or how, but I tried again and now its compiling fine. The only change was that I had compiled the project a few times under Xcode 9.x in between. So will mark this as solved- thanks for the help everyone!