[lion] XCode 4.1 doesn't install with lion

hi


first, sorry for my english...


I had an Imac 2010 with a hard drive 1.5 To who had 1 To free


1) i make upgrade snow leopard to lion

2) Xcode was installed for SL before i made upgrade

3) from appstore, i download XCode 4.1

4) few seconds after install begin, i received this message :


"The installer encountered an error that caused the installation to fail. Please consult /var/log/install.log for more details"


5) i decided to install lion from an usb key


6) i download for the second time XCode 4.1 but i received the same message


Could you help me please


if i open terminal and tape this "nano /var/log/install.log" i obtain this

Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: @(#)PROGRAM:Install PROJECT:Install-684
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: @(#)PROGRAM:IA PROJECT:InstallAssistant-197
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Hardware: iMac11,3 @ 2.93 GHz (x 8), 8192 MB RAM
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Running OS Build: Mac OS X 10.7 (11A511)
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: PATH=/usr/bin:/bin:/usr/sbin:/sbin
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: PWD=/
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: SHLVL=1
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: __OSINSTALL_ENVIRONMENT=1
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: CI_DEFAULT_OPENCL_USAGE=0
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: OS_INSTALL=1
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Env: _=/System/Installation/CDIS/LCA.app/Contents/MacOS/LCA
Jul 22 00:44:27 new-host-3 Install Mac OS X Lion[355]: Using distribution archive from /Volumes/Image Volume/Packages/OSInstall.mpkg
Jul 22 00:44:28 new-host-3 Install Mac OS X Lion[355]: Using product <OSInstallDVDProduct> based on media at /Volumes/Image Volume at distance 10
Jul 22 00:44:28 new-host-3 Install Mac OS X Lion[355]: Using product <OSInstallESDProduct> based on distribution at /Volumes/Image Volume/Packages/OSInstall.mpkg at distance 5
Jul 22 00:44:28 new-host-3 Install Mac OS X Lion[355]: Checking Software Update catalog URL http://swscan.apple.com/content/catalogs/others/index-lion-snowleopard-leopard.m erged-1.suc$
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ->T+[DMToolBootPreference getPartitionBootability:]: inUDS=0x10674dc30=disk0s2=Macintosh HD
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ..T+[DMToolBootPreference getPartitionBootability:]: PMBootable=1 (bootable right now without any further action)
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ..T+[DMToolBootPreference getPartitionBootability:]: PMBootCapable=0 (bootable if you call MKCFPrepareBootDevice)
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ..T+[DMToolBootPreference getPartitionBootability:]: PMBootSurgeryRequired=0 (for primitive MBR on BIOS, add boot block and loader)
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ..T+[DMToolBootPreference getPartitionBootability:]: PMFSSurgeryRequired=0 (for primitive MBR on BIOS, add boot block and loader)
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM ..T+[DMToolBootPreference getPartitionBootability:]: PMNewfsRequired=0 (bootable with MKCFPrep but it will rudely carve)
Jul 22 00:44:28 new-host-3 diskmanagementd[343]: DM <-T+[DMToolBootPreference getPartitionBootability:]: MKerr=0 out=4=0x4
Jul 22 00:44:28 new-host-3 Install Mac OS X Lion[355]: No available package ref for compatibility update. Ignoring.
Jul 22 00:44:41 new-host-3 Install Mac OS X Lion[355]: Created IATool object:8c3a140
Jul 22 00:44:42 new-host-3 Install Mac OS X Lion[355]: No available package ref for compatibility update. Ignoring.
Jul 22 00:44:42 new-host-3 Install Mac OS X Lion[355]: Preventing machine sleep.
Jul 22 00:44:42 new-host-3 Install Mac OS X Lion[355]: Using product IA_PKSecureNetEnabledProduct <file://localhost/Volumes/Macintosh%20HD/Mac%20OS%20X%20Install%20Data/> at distance 5
Jul 22 00:44:42 new-host-3 Install Mac OS X Lion[355]: Using mutable product path: /Volumes/Macintosh HD/Mac OS X Install Data
Jul 22 00:44:44 new-host-3 Install Mac OS X Lion[355]: Using product <OSSoftwareUpdateCatalogProduct> from product keys 11A511_ServerEssentials at distance 25
Jul 22 00:44:45 new-host-3 Install Mac OS X Lion[355]: Retrieving 50 packages (3.716 GB)
Jul 22 00:44:45 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.MacOSX.lang.da (file://localhost/Volumes/Image%20Volume/Packages/Danish.pkg)
Jul 22 00:44:46 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.MacOSX.lang.pl (file://localhost/Volumes/Image%20Volume/Packages/Polish.pkg)
Jul 22 00:44:49 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.pkg.MediaFiles (file://localhost/Volumes/Image%20Volume/Packages/MediaFiles.pkg)
Jul 22 00:44:49 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.pkg.AddressBook (file://localhost/Volumes/Image%20Volume/Packages/AddressBook.pkg)
Jul 22 00:44:50 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.MacOSX.lang.de (file://localhost/Volumes/Image%20Volume/Packages/German.pkg)
Jul 22 00:44:50 new-host-3 Install Mac OS X Lion[355]: Retrieved package com.apple.MacOSX.lang.sv (file://localhost/Volumes/Image%20Volume/Packages/Swedish.pkg)

iMac, Mac OS X (10.6.8)

Posted on Jul 22, 2011 9:47 AM

Reply
97 replies

Jul 28, 2011 9:07 AM in response to jimweast

Intro:

- I have MacBook Pro from the end of 2009

- I had Leopard, upgraded to Snow Leopard and yesterday upgraded to Lion

- All this time I had XCode installed in its latest release version

- Today I have downloaded the Lion version of XCode (4.1) from the AppStore


The problems:

- In the begining I had the same problem as you write here (couldn't instal and got a message to look in the log file)

- After that I have installed and used the MacKeeper (there are many similar solutions for Mac cleaning and repairing)

- After that repair I succeeded to start installing the XCode 4.1

- In the first attempt after about 2 hours of installation the installer told me that I have to close iTunes in order to proceed, but the iTunes was closed (I tried to open and close the iTunes with no luck)

- After that I have force-closed the installer, restarted the Mac and started the second attempt (without opening anything accept the installer)

- After additional couple of hours I've noticed that the progress doesn't move (at about 80%)


Will it ever work?

Jul 29, 2011 9:36 AM in response to jimweast

I just installed Xcode from the App Store on a new MacBook Air (Mid-2011) running Lion that my friend got a week ago. It installed just fine. Downloaded, clicked Install Xcode, and it ran as soon as it was finished installing. I would say if there is any way you can completely uninstall Xcode, as in clearing it out of caches and other areas, then it might work. If you do a clean install of Snow Leopard and then install Lion, I think it will work without fail.

Jul 29, 2011 11:58 AM in response to jimweast

In my case, I did a clean install of lion, download the xcode from appStore, search and install system updates (including iTunes) and after that, i tryed to install and the installer told me that I have to close iTunes in order to proceed. I just reboot my system kill the iTunesHelper process on the monitor activies before run the installer again and it works..

Jul 31, 2011 10:52 AM in response to l.baum

ok guys, so I've fixed the issue for me.


Small recap: the XCode package downloaded from the AppStore wouldn't install on my machine. I have an absolutely pristine OS 10.7 Lion installed, so any software incompatibility or configuration problem can be ruled out. The problem manifested as "An error occurred while extracting files from the package DeveloperTools.pkg" ... (so to read in /var/log/install.log). Several re-installs of the OS and re-downloads of XCode did not help. (However, it was sometimes a different package that caused the error).


The cause: the fact that in my different downloaded XCode installers, different packages caused errors made me think that there are problems in the AppStore (or its caching infrastructure), resulting in corrupt XCode packages. Luckily, over time, the caching servers from the AppStore return different XCode packages... some seem to be perfectly okay (as people report that they could install XCode without any problems), others are corrupt.


The solution: I took several different (corrupt) XCode packages and combined them into one "clean" package. Here is how:

1. run the XCode installer

2. check /var/log/install.log, which package made the installer abort

3. open the XCode installer package (in Finder, right-click, the choose "show package contents"), navigate to Contents/Resources/Packages

4. remove the corrupt package from that folder

5. take another downloaded XCode installer package, open it in the same way as in step 3

6. copy the corresponding package from there to the Contents/Resources/Packages folder in your original Installer -- and keep your fingers crossed, that this copied package is not corrupt

7. run the XCode installer again -- if you're lucky, the package identified in step 2 will run fine

8. if the installation aborts at another package, go back to step 2


I had to exchange 4 or 5 packages, but then I finally ended up with having a working XCode installer.

Aug 2, 2011 8:38 AM in response to jimweast

Add me to the list...


Aug 2 06:40:44 sanders-macbook _securityagent[1461]: Running Install Scripts . . .

Aug 2 06:40:44 sanders-macbook _securityagent[1463]: Begin script: AlertAll.sh

Aug 2 06:40:44 sanders-macbook installd[1200]: ./preinstall: Guest is not in the sudoers file. This incident will be reported.

Aug 2 06:40:44 sanders-macbook _securityagent[1469]: End script: AlertAll.sh

Aug 2 06:40:44 sanders-macbook _securityagent[1470]: Begin script: preflight

Aug 2 06:40:44 sanders-macbook _securityagent[1473]: End script: preflight

Aug 2 06:40:44 sanders-macbook _securityagent[1474]: Begin script: writelocation

Aug 2 06:40:44 sanders-macbook _securityagent[1477]: End script: writelocation

Aug 2 06:40:44 sanders-macbook _securityagent[1478]: Begin script: zzzcleanup

Aug 2 06:40:44 sanders-macbook _securityagent[1482]: End script: zzzcleanup

Aug 2 06:40:44 sanders-macbook _securityagent[1483]: 4 Install Scripts run.

Aug 2 06:42:40 sanders-macbook installd[1200]: PackageKit: Install Failed: Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “DeveloperTools.pkg”." UserInfo=0x7fb194971e80 {NSFilePath=./preinstall, NSURL=file://localhost/Applications/Install%20Xcode.app/Contents/Resources/Packages/DeveloperTools.pkg, PKInstallPackageIdentifier=com.apple.pkg.DeveloperToolsLeo, NSLocalizedDescription=An error occurred while running scripts from the package “DeveloperTools.pkg”.} {

NSFilePath = "./preinstall";

NSLocalizedDescription = "An error occurred while running scripts from the package \U201cDeveloperTools.pkg\U201d.";

NSURL = "file://localhost/Applications/Install%20Xcode.app/Contents/Resources/Packages/DeveloperTools.pkg";

PKInstallPackageIdentifier = "com.apple.pkg.DeveloperToolsLeo";

}

Aug 2 06:42:40 sanders-macbook installer[1440]: install:didFailWithError:Error Domain=PKInstallErrorDomain Code=112 "An error occurred while running scripts from the package “DeveloperTools.pkg”." UserInfo=0x7faf016de2d0 {NSFilePath=./preinstall, NSURL=file://localhost/Applications/Install%20Xcode.app/Contents/Resources/Packages/DeveloperTools.pkg, PKInstallPackageIdentifier=com.apple.pkg.DeveloperToolsLeo, NSLocalizedDescription=An error occurred while running scripts from the package “DeveloperTools.pkg”.}

Aug 2 06:42:41 sanders-macbook installer[1440]: Install failed: The Installer encountered an error that caused the installation to fail. Contact the software manufacturer for assistance.


Xcode freshly downloaded from App store on a fresh Lion installation (not an upgrade). I even redownloaded the installer: same error...

Aug 2, 2011 1:45 PM in response to jimweast

I would love to, but it seems to fail on the same package for the third time now so there is not much to exchange :-(

I find it strange that this can happen, if it indeed is file corruption during transfer. For one, it should not happen; a corrupt Lion installer for instance could result in strange results. Furthermore, I don't think the corruption takes place between the App store and the user (me) because too many people see the installation fail at the same package. I had it fail 3x at the same point. Too much of a coincidence...

This thread has been closed by the system or the community team. You may vote for any posts you find helpful, or search the Community for additional answers.

[lion] XCode 4.1 doesn't install with lion

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.