Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Default frameworks missing in Xcode 6 beta

Tags:

xcode

ios

xcode6

While creating a new project in "Xcode 6 beta", I noticed that there are no frameworks attached.

In Xcode 5.x, when we created a new project, we had the following frameworks linked by default:-

  1. Foundation
  2. CoreGraphics
  3. UIKit
  4. XCTest

The frameworks that are linked when you create a new SingleViewController project in Xcode 5.x Default Xcode 5.x frameworks

The MISSING frameworks when you create a new SingleViewController project in Xcode 6 beta No default frameworks for Xcode 6 beta

I do understand that this is a beta release of the IDE. But it will help if we come to know whether these frameworks are now linked internally?

Thanks in advance.

like image 593
footyapps27 Avatar asked Sep 30 '22 14:09

footyapps27


1 Answers

In Xcode 6, the default for new projects is to use the module system (introduced in Xcode 5) to automatically link any frameworks you reference in code via import (Swift) or @import/#import statements (ObjC). Because the project template contains code that imports Foundation and UIKit (and a test case target that imports XCTest), you get those frameworks linked automatically.

As Alladinian commented, there's a switch to enable or disable this in the project settings, so you can turn it on for old projects, too. (Or turn it off if it gives you trouble.). Once your frameworks are automatically linked, you don't need to put them in Linked Frameworks & Libraries anymore.

And if you want to start using other frameworks in your project, you don't need to add them I'm the project settings, either—just import MapKit or CloudKit or AVFoundation or whatever in your source code and they'll automatically get linked.

like image 108
rickster Avatar answered Oct 03 '22 08:10

rickster