Very confused about XCode 4 (after upgrading from 3.x) - xcode

My world was perfect when I had XCode version 3.x (3.1 or 3.2?).
Then one day, after upgrading my iPhone device to ios 4, i tried to deploy an app to my device. For some reason I thought that i needed XCode 4 (or SDK 4) in order to deploy directly to an ios 4.0 device (via xcode) because it was giving me an error(s) i've never seen before that seemed it was suggesting I upgrade XCode/SDK.
So now i have XCode 4.0 installed (build 4A304a) and am in a situation where I can't build my code, things are breaking left and right, and on top of it all I have to learn XCode all over again!!
Now here are my questions:
A) Do I need XCode 4 (and/or SDK 4) in order to deploy directly to an ios 4 device?
B) Do I have the right version of XCode?
C) I think there is a new Xcode version out, 4.02 or something. Should I get that right away?
D) Every time I download a new XCode, does it install "next" to the previous XCode versions? (it is a completely new XCode installation or does it upgrade any existing versions?)

Taking your questions in order:
A) Do I need XCode 4 (and/or SDK 4) in
order to deploy directly to an ios 4
device?
No, you can happily use Xcode 3.x to deploy to an iOS 4.x device. That said, if you want to develop using SDK features that are only present in SDK 4.3 or greater, you'll need to use Xcode 4.x as Xcode 3.x is only available as a package with version 4.2 of the SDK.
B) Do I have the right version of
XCode?
Being realistic, you'll need to move to using Xcode 4.x at some point, so you might as well bite the bullet now and get used to the new environment. Whilst it might take a while, it's worth the transition. (IMHO.) :-)
C) I think there is a new Xcode
version out, 4.02 or something. Should
I get that right away?
As Xcode 4.x is still fairly new they're patching it quite frequently. As such, if bandwidth isn't an issue, you might as well stay on top of Xcode releases. That said, unless you encounter a bug that's specific to a release, there's no requirement for you to do this.
D) Every time I download a new XCode,
does it install "next" to the previous
XCode versions? (it is a completely
new XCode installation or does it
upgrade any existing versions?)
By default Xcode will install over any existing versions. However, you can select a different destination during the install process if you want to run multiple versions in parallel.

Upgrading to Xcode 4 is indeed disruptive, luckily Apple doesn't do that too often. My experience with Apple technology is that you better go with the latest.
Personally: It took me 3 weeks to become break even in productivity. Now I'm more productive.
A: dunno, probably
B: yes
C: yes
D: in apple's tradition: it overwrites

Related

What happen if I remain to use old Xcode version?

I'm trying to understand, what will happen if one remains to use older Xcode version for developing, building and deploying.
I understand that each new Xcode version (...10,11,12) comes with new SDK support, improvements and features. I also have a great example of, we'll need the latest Xcode 12 to deploy our app to iOS 14 and above, since it won't work for Xcode 11 and below.
[Scenario ques]
However, what are the possible issues if one decided to continue in building and deploying their app with Xcode 11(SDK iOS13)?
Aside from not being able to test the app in a proper iOS 14 environment and risking of having bugs. Could the SDK version in Xcode11 and Xcode12 make any difference to the app?
You can certainly go on playing with Xcode 11 if that is what you feel like doing. But that's all you will be doing - playing. You won't be able to do anything with an app that you create that way. In particular, without Xcode 12, you cannot run the app on a device with iOS 14 on it, and you cannot submit the app to the App Store.
So when you say
use older Xcode version for developing, building and deploying
...you can just delete the word "deploying"; you won't be doing that (if the word "deploying" means what it usually means).
(And you cannot easily develop an app partly with Xcode 12 and partly with Xcode 11, as some of the things you do in Xcode 12 can make the project incompatible with Xcode 11.)

When I attached my device to the xcode and try to build my project it's generating error

Could not locate device support files.
This iPhone 5s (Model A1457, A1518, A1528, A1530) is running iOS 10.3.1 (14E304), which may not be supported by this version of Xcode.
You need to update Xcode whenever the iOS version you want to work with is higher than the highest version that Xcode's simulator has installed. This can be done one of two ways. The simplest is to use the App Store to download/update Xcode. If the App Store doesn't show any updates, you must manually download the latest Xcode build from https://developer.apple.com/.
You will need to manually download from the Developer portal when the version of Xcode on your computer was downloaded there previously. For example, many beta testers may download the file directly instead of using the Mac App Store, since it is a beta download.
I would recommend trying to keep updates done through the App Store by downloading Xcode from there initially. The benefit to this is that it can automatically update as well as save space on your computer (Xcode is a big file, and you may not have enough space to download a new version if you still have the old version).
As of the comments, I will now write an answer. :-)
Whenever you encounter this error there might be two reasons for that:
The OS version is too old
The iPhone's/iPad's OS is too new for your Xcode version
If it is too old, you may need to download older SDKs and OS versions.
You can do so in Xcode. Go to "Preferences" -> "Components" and download the appropriate Simulator.
If the devices OS is up to date, you have to make sure your Xcode is also up to date.
Either you update Xcode through the AppStore OR (and I prefer this way, as the AppStore is used to hang up in a certain state and cannot be completed any longer until you restart the Mac, at least I had this several times).
Side note: Xcode requires multiple GB of free storage. Make sure you have enough free storage left for an update.
You can download the latest Xcode version from the https://developer.apple.com portal:
Go to Downloads:
And then select the item of interest (in your case Xcode)

Problems with Xcode 7.2.1

just install the new version of Xcode (7.2.1), he took a little longer than expected.
But when it finished and run the xcode continues with version 7.1.1
I thought it would be solved by restarting the Mac, but no.
Any idea what can be spent? or happened to me to be done?
!EDITED!
My MAC version.
My xcode options
My applications
I had exactly the same problem. I installed 4GB large 7.2.1 version of Xcode from the AppStore over an existing 7.2 version, and whichever way I was launching Xcode it was always the same old 7.2 popping up. What was worse I could not download 7.2.1 again, as AppStore app was not showing Install button anymore, but rather Launch button instead (like it was installed).
Finally I found a solution. I went to Downloads for Apple Developers site (a login to a developer account was required), I dowloaded Xcode_7.2.1.dmg 4.7GB large from there, launched an installation... which successfully replaced the older 7.2 version of Xcode.
Another answer suggests installing Xcode via a Developer Member Center download. I'd like to caution against this, and suggest an alternative approach.
Shortly before Xcode 7 became available, I upgraded an Xcode 6 installation to 6.4 by using the download. I did this to save download time for upgrading multiple machines (I put the installer on a flash drive). I subsequently discovered that using the downloaded installer broke tracking the version history in the App Store, and I was no longer able to upgrade via the App Store. Also, I was no longer notified of pending Xcode updates via the MAS "Updates" panel.
So a possible consequence for you may be that the App Store may not be able to handle your future Xcode updates, or even notify you when an update is pending.
What I ended up doing was deleting my then-current Xcode installation (I used AppDelete to get all of the components of the installation), and starting from scratch using the App Store. I recommend doing the same. Probably the best way to start is to try deleting Xcode via Launchpad. But if that doesn't work (say, it doesn't delete all versions if you still have multiple versions), try AppDelete or a similar app.
I should note that one reason I used the download to upgrade Xcode 6 was that I'd done so previously without breaking the App Store's ability to track Xcode's version history. Whether that previous behavior was a fluke, or whether the later behavior (losing the version history) was a fluke, I can't say.
If you've already installed via the Member Center installer, you can check to see if you'll have this problem by looking up Xcode in MAS. If the store shows you have the version you manually installed, then all is well (probably!). If not, either you'll have to keep track of updates by yourself, or you should re-establish MAS version tracking by deleting Xcode and starting from scratch via MAS. I'd be interested to learn whether the store is tracking your manual installation.

am I safe to upgrade my cocos2d 2.1 game to XCode 6 to support iPhone 6?

I have been working on a game that is 95% done, and have been working in Snow Leopard with XCode 5.0.2, intentionally not upgrading to prevent any complications since I am so close. My other team mate got a new computer with mavericks and was using XCode 6, and so I attempted to upgrade XCode to 5.1.1--- when I did this, my entire project was full of errors and a disaster...
My question is, if I plan to release my game and have it tested on a new iPhone 6, do I need to install Mavericks + XCode? I absolutely do not want to go through the pain of upgrading my game to cocos2d 3.0, and I am afraid if I try to run a 2.1 game on the latest XCode its all going to blow up and not work (just as it did even with 5.1.1).........
In order to submit your App to the app store, you are going to have to submit it using at least Xcode 5.1.1

How can I install Xcode 6 along side Xcode 5?

I was wondering if there is a way that I could install Xcode 6 along side Xcode 5. I've seen people say you could but they haven't really explained why. Can someone help to explain why? Also, how would you uninstall it if I wished to in the future?
It's simple. The Xcode 6 beta is named Xcode6-beta.app and you drag install it into /Applications. The GM version of Xcode is called Xcode.app. If you need to switch the command line tools you use xcode-select. Nothing has changed here. It's the same as it's been. When you want to "uninstall" it, drag it to the trash. It's that simple.
You can also change the default command line tools via GUI, if you prefer: XCode > Preferences > Locations, Dropdown "Command Line Tools"...
Attention, you can effectively install Xcode 6 and keep Xcode 5 but this is not working perfectly fine. For example this broke my Xcode 5 IOS6 simulators and I am now unable to run my apps on this old ios version (see here)
I didn't find any solution for now and there may be others problems, so be aware this operation is not without risks
You might be far better off creating a partition with OSX Yosemite and installing Beta Software there. I moved over my apps to the Yosemite partition and only the Xcode 6 Beta 4 ran them - yeah!
Here is where I will work with untested software.
Good luck!

Resources