1
votes

guys, I really need someone's help. I am a newbie in iOS development, however everything went fine until I have accidentally deleted an entire Main.storyboard file instead of a single view. I have this file in my trash bin and I have tried to put it back but now the project is not compiling and throws this error instead:

Ld /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Products/Debug-iphonesimulator/Test111.app/Test111 normal i386 cd /Users/Sergio/Projects/Test111 export IPHONEOS_DEPLOYMENT_TARGET=7.1 export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/usr/bin:/Applications/Xcode.app/Contents/Developer/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin" /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -arch i386 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator7.1.sdk -L/Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Products/Debug-iphonesimulator -F/Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Products/Debug-iphonesimulator -filelist /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Intermediates/Test111.build/Debug-iphonesimulator/Test111.build/Objects-normal/i386/Test111.LinkFileList -Xlinker -objc_abi_version -Xlinker 2 -fobjc-arc -fobjc-link-runtime -Xlinker -no_implicit_dylibs -mios-simulator-version-min=7.1 -framework CoreLocation -framework MapKit -framework CoreGraphics -framework UIKit -framework Foundation -Xlinker -dependency_info -Xlinker /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Intermediates/Test111.build/Debug-iphonesimulator/Test111.build/Objects-normal/i386/Test111_dependency_info.dat -o /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Products/Debug-iphonesimulator/Test111.app/Test111

duplicate symbol _spacing in: /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Intermediates/Test111.build/Debug-iphonesimulator/Test111.build/Objects-normal/i386/ChatViewController.o /Users/Sergio/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn/Build/Intermediates/Test111.build/Debug-iphonesimulator/Test111.build/Objects-normal/i386/AllMessagesViewController.o ld: 1 duplicate symbol for architecture i386 clang: error: linker command failed with exit code 1 (use -v to see invocation)

What can I do to revert everything back?

2
Restore from your backup.Hot Licks
There is none, that's the problemSergio

2 Answers

0
votes

Maybe you can try to delete the DerivedData folder related to your project.

Open your terminal, and type:

rm -Rf ~/Library/Developer/Xcode/DerivedData/Test111-gnlasierruehmngkenyhntisfyrn

After that, rebuild your project and try again.

0
votes

Ok, I have figured this out on my own. There was some problem with two files - ChatViewController.m and AllMessagesViewController.m as you can see from the error log. Something has messed up there with the "spacing" variable when the storyboard file was deleted. So I have just deleted one of the conflicting files and rebuilt the project.

Learn to read logs.