0

I am getting an extremely frustrating error from the compiler in one of my projects. After changing a few compiler settings for optimization, things were working beautifully, until I tried to test on the simulator. I get this error:

ld: in /Users/eric/Library/Developer/Xcode/DerivedData/My_Awesome_App-
hcpskretrcpxnuctkkvwptohgmib/Build/Intermediates/My_Awesome_App.build/Debug-
iphonesimulator/My_Awesome_App.build/Objects-normal/i386/main.o, could not parse object 
file /Users/eric/Library/Developer/Xcode/DerivedData/My_Awesome_App-
hcpskretrcpxnuctkkvwptohgmib/Build/Intermediates/My_Awesome_App.build/Debug-
iphonesimulator/My_Awesome_App.build/Objects-normal/i386/main.o: Malformed metadata record 
for architecture i386

I reset the compiler settings as best as I could, but still the error persists. I tried the suggestions in Malformed metadata record for architecture i386 but still nothing. Any other things I can do? Like reset Xcode/LLVM-GCC to defaults?

Community
  • 1
  • 1
eric.mitchell
  • 8,817
  • 12
  • 54
  • 92
  • And have you actually tried what you suggest (reset to defaults)? – fge Dec 18 '11 at 23:19
  • Well if there is a 'reset all settings to defaults' button I missed it. I tried changing everything back to as close as possible to what it was before, but the reversion was not exhaustive. How would you suggest I do that? – eric.mitchell Dec 18 '11 at 23:26

1 Answers1

0

Found it- I compared the project's build settings to the settings of the same project in a backup I had on an external HD from just two days ago, and the culprit was the Link-Time Optimization flag, which was set to yes. Setting it to NO fixed the problem. Another reason to keep regular backups!

eric.mitchell
  • 8,817
  • 12
  • 54
  • 92