Today I had some free time, so I decided to upgrade my MacBook Pro to have the latest version of Xcode. Apple recently released Xcode 4.3.1 which supports the iOS 5.1 SDK. I figured it wouldn’t take more than an hour. Six and a half hours later, I am writing this post so others can hopefully avoid the frustration I just went through.
If you can’t install Xcode 4.3.1 from the App Store after a failed attempt, open the Launchpad app, then open the Developer group, and delete the Xcode icon with the download progress bar. Then you can go back into App Store and restart the installation process.
The Gory Details
First I tried installing Xcode 4.3.1 using the App Store in OS X Lion, but my system froze 45 minutes into the download. That killed the installation process, and I was not able to restart the download/install, even after a reboot. When I attempted to install it again from the App Store, I’d click the Install button and nothing would happen. Once in a while it would ask me for password, but nothing beyond that.
Then I downloaded the DMG file from developer.apple.com, which took an hour or so, but when I finally opened it, I got an “invalid checksum” error. Grr.
So I redownloaded the DMG file, in case the initial download somehow got corrupted. Same result an hour later: invalid checksum. It turns out that if you click the “Stop” button on the dialog that is shown before the error message, it will skip verifying the checksum and Xcode will open up. But who knows what kind of trouble that is begging for…
At this point, I couldn’t install Xcode from the App Store and didn’t want to run some invalid DMG file all the time. After trying everything I could think of, I finally opened up the Launchpad app, in the Applications folder. In that app, I saw a “Developer” group full of icons. I opened it up and found an icon of Xcode with the “pause” symbol next to a download progress bar.
I then tapped and held on that Xcode icon in the Launchbar screen until the icons started jiggling, at which point I could delete the Xcode icon from the Developer group. Following that I closed Launchpad, opened up the App Store again, and was able to start installing Xcode again by clicking the Install button.
I hope this helps somebody out there.