Questions tagged [xcode]

Xcode is Apple's integrated development environment (IDE). USAGE NOTE: Use this tag only for questions about the Xcode IDE itself, and not for general Mac or iOS programming topics. Use [cocoa] for Mac programming questions, and [cocoa-touch] or [iOS] or [Swift] for iOS programming questions.

Xcode is Apple's integrated development environment (IDE) tool, which runs on . It is used for creating apps for macOS (), iOS (), iPadOS (),watchOS () and tvOS () platforms.

This tag should be used only for questions about the Xcode tool itself, not for programming questions for which you happen be using Xcode - if your question would stay the same if you used and for writing your program, avoid adding this tag.

  • For macOS programming questions, use the or tag.

  • For iOS programming questions, use the or tags.

  • For Apple Watch programming questions, use the , or tags.

  • For questions about the Objective-C language and its features, use the tag.

  • For questions about the Swift language and its features, use the tag.

Latest Versions:

  • Current stable version is Xcode 14.2 released on December 13, 2022
  • Beta version is Xcode 14.3 RC released on March 21, 2023

Release notes:

SDKs in Xcode 14

  • iOS 16
  • iPadOS 16
  • tvOS 16
  • watchOS 9
  • macOS 13

This tag covers:

  • Project organization
  • Source code editing
  • Build system
  • Unit testing
  • Xcode Instruments
  • Interface Builder (prior to Xcode 4, Interface Builder was a separate app, in which case you would use the tag)

More information:

Related:

Related tags for specific versions:

158769 questions
52
votes
7 answers

Generating Swift models from Core Data entities

Update for Xcode 8: In Xcode 8, one needs to go to the Core Data Model Editor and Show the File Inspector. Near the bottom is an option for code generation. Select Swift. Edit: I found the solution to generate a Swift model from Core Data entity: On…
Jean Lebrument
  • 5,079
  • 8
  • 33
  • 67
52
votes
2 answers

No architectures to compile for (ONLY_ACTIVE_ARCH=YES, active arch=x86_64, VALID_ARCHS=armv7 armv7s)

Running in Xcode is correctly, but when I want to use command line with $ /usr/bin/xcodebuild -scheme projectA -workspace projectA.xcworkspace -configuration Debug clean build And come up with the following. === BUILD NATIVE TARGET projectA OF…
Edward Chiang
  • 1,133
  • 2
  • 12
  • 24
52
votes
4 answers

Very slow tab switching in Xcode 4.5 (Mountain Lion)

I recently updated my MacBook Pro (2.3 GHz Intel Core i5) from Lion to Mountain Lion and simultaneously upgraded Xcode to the latest 4.5 version. I've experienced one very irritating problem. While programming I'm used to have a couple of tabs…
Anden87
  • 970
  • 1
  • 9
  • 19
52
votes
2 answers

What is PurpleEventCallback?

In the stack trace of my iPhone application, I see a call to something called PurpleEventCallback. I wasn't able to find any documentation for it. What is this?
Manav
  • 10,094
  • 6
  • 44
  • 51
52
votes
6 answers

Getting the correct bounds of UIViewController's view

I have an iPad-application. In landscape orientation the UIViewController's view actual width = 1024px and height = 768 - 20 (statusBar) - 44 (navigationBar) = 704px. So I wanna get this [1024 x 704] size and I'm using self.view.bounds for it. It…
demon9733
  • 1,054
  • 3
  • 13
  • 35
51
votes
16 answers

Xcode will run app on simulator but not on device

I receive the following error when trying to run the app on my device. error: failed to launch '/Users/michael/Library/Developer/Xcode/DerivedData/Build/Products/Debug-iphoneos/Word Processor.app/Word Processor' -- No such file or directory…
Rahul Iyer
  • 19,924
  • 21
  • 96
  • 190
51
votes
7 answers

Xcode 4 why do I see XML when clicking on MainStoryBoard.storyboard: seems like a bug

In an Xcode project, I see XML when clicking on MainStoryBoard.storyboard instead of the graphical design, why and how to restore the right view ? Update: I think it's a bug of XCode 4.2 because on another project, when I click on version editor I…
user310291
  • 36,946
  • 82
  • 271
  • 487
51
votes
9 answers

How to remove tmp directory files of an ios app?

I'm working on an app that uses the iPhone camera and after making several tests I've realised that it is storing all the captured videos on the tmp directory of the app. The captures don`t disappear even if the phone is restarted. Is there any way…
oniglo
  • 511
  • 1
  • 4
  • 3
51
votes
6 answers

Auto generate method comment in Xcode

Is there a way in Xcode to generate method comment automatically similar to what you do in Eclipse for javadoc comments. For example press you may hit /** one row before a method declaration and eclipse automatically generates the skeleton of…
L. Kvri
  • 1,456
  • 4
  • 23
  • 41
51
votes
10 answers

Unable to process application info.plist validation at this time due to a general error (1095)

I am creating a newsstand application. the application is ready, now i am trying to upload the app in apple store using Application Loader. While uploading the zip file its showing the error message as Unable to process application info.plist…
Naveen
  • 900
  • 1
  • 7
  • 23
51
votes
4 answers

Combine static libraries on Apple

I tried the approach in this question, but it seems the linux version of ar is not the same as the mac version since I failed to combine the object files again. What I basically want to do is is merge another static library into my Xcode static…
user187676
51
votes
5 answers

Xcode can build a project but can't run it on simulator

When I download a project from the web, sometimes it can be built but doesn't run (XCode -> Product -> Run is disabled, in grey). This never happens when I create projects myself. What could be the problem? Is it somehow connected with version? I'm…
Eugene Chumak
  • 3,272
  • 7
  • 34
  • 52
51
votes
1 answer

Instruments 4.1 unresponsive to projects launched from Xcode 4.1 until pressing Cmd-Tab

If I open Instruments and select a standard application (e.g. Mail or MS Word) it has no issue. If I am in Xcode and I go to Product > Profile (or press Cmd + I), it launches Instruments, allows me to select a template, and loads the standard…
James Paul Mason
  • 1,051
  • 1
  • 13
  • 27
51
votes
9 answers

How to check iOS app size before upload

I would like to be able to check the size of my app before submitting to the app store. More specifically I need to know whether it will be below the magic 20 MB, to allow cellular downloads, since the app is created for a festival.
ViggoV
  • 2,133
  • 2
  • 20
  • 22
51
votes
2 answers

Xcode: how to make it stop opening extra windows?

Every time I double click a file it opens it in a new window. (If I single click then it shows it in the main window). I just want it to open the thing in the main window, regardless of if I double click or single click it. Kind of like how visual…
Shai UI
  • 50,568
  • 73
  • 204
  • 309