I am trying to install xcode 4.1 with lion. Apparently at 3/4 of the installation problem, it says to close itunes, which is not open. How can I fix the problem?
Use Activity Monitor, and locate the iTunes Helper process and kill it. As per an Apple support discussion and several other sources.
Update: The latest Xcode installer has been fixed and this should not be an issue now.
I encountered this problem with Xcode as well. The solution I found was that iTunes was open in another account. iTunes must be quit in all acounts to complete the installation. Also make sure that you quit iTunes(command q)not just close all the windows. Those are the two most likely reasons for that error message.