Faltan marcos predeterminados en Xcode 6 beta

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

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

  1. Fundación
  2. CoreGraphics
  3. kit de interfaz de usuario
  4. Prueba XCT

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

LA DESAPARECIDO frameworks when you create a new SingleViewController proyecto en Xcode 6 beta No default frameworks for Xcode 6 beta

Entiendo que esto es un beta lanzamiento de la IDE. But it will help if we come to know whether these frameworks are now linked internally?

Gracias de antemano.

preguntado el 12 de junio de 14 a las 10:06

Don't quote me on this, but I think they are indeed linked internally. Since if you look at the code, there's the import UIKit line and it doesn't give any errors (Swift project). -

They are imported as modules and linked automatically. In fact you could do this in Xcode5.x as well (for system frameworks) provided that you set Enable Modules & Link Frameworks Automatically a Yes in Apple LLVM 5.1 - Language - Modules sección de Build Settings -

@LordZsolt you are correct. Foundation is automatically linked. You should make this into an answer. -

1 Respuestas

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.

respondido 02 nov., 14:19

No es la respuesta que estás buscando? Examinar otras preguntas etiquetadas or haz tu propia pregunta.