Mount the Xcode 3.2.6 DMG and open Terminal
Enter commands:
sh-3.2# export COMMAND_LINE_INSTALL=1
sh-3.2# open /Volumes/Xcode\ and\ iOS\ SDK/Xcode\ and\ iOS\ SDK.mpkg/
You are now able to install Xcode 3.2.6 on Lion with no package modifications!
If the installer dialog while stage “Updating files…” show you this dialog:
In order to continue installation, please close the following application:
iTunes
but you think that have no iTunes opened, open Activity Monitor (located in Applications/Utilities),
Start typing “iTunes” into the filter box in the top right
Select iTunesHelper from the list and click the Quit Process button.
Don’t work?
Try second method:
- Download the Xcode 3.2.6 disk image, ‘xcode_3.2.6_and_ios_sdk_4.3.dmg’, (I will assume it’s in ~/Downloads for the next steps).
- Open up the Terminal and change to the directory where the image resides:
1 | cd ~/Downloads |
- Attach the disk image with a shadow image to make it writable. Terminal command (as one line):
1 | hdiutil attach -shadow xcode_3.2.6_and_ios_sdk_4.3.shadow xcode_3.2.6_and_ios_sdk_4.3.dmg |
-Remove the string ‘&& system.compareVersions(my.target.systemVersion.ProductVersion, ’10.7′) < 0 ‘ from line 148 in ‘Xcode and iOS SDK.mpkg/Contents/iPhoneSDKSL.dist’. Assuming the disk image got mounted at ‘/Volumes/Xcode and iOS SDK’, you can use this one-liner:
1 | cat '/Volumes/Xcode and iOS SDK/Xcode and iOS SDK.mpkg/Contents/iPhoneSDKSL.dist' | sed "s/&& system.compareVersions(my.target.systemVersion.ProductVersion, '10.7') < 0 //g" > '/Volumes/Xcode and iOS SDK/Xcode and iOS SDK.mpkg/Contents/iPhoneSDKSL.dist.new' && mv '/Volumes/Xcode and iOS SDK/Xcode and iOS SDK.mpkg/Contents/iPhoneSDKSL.dist.new' '/Volumes/Xcode and iOS SDK/Xcode and iOS SDK.mpkg/Contents/iPhoneSDKSL.dist' |
Install Xcode!
done.
Ref: albertopasca.it
Ref: Catacombae

















