I am receiving the following error when building my project.
duplicate symbol _OBJC_CLASS_$_PrintAdventureMenuViewController in:
/Users/ethanraymond/Library/Developer/Xcode/DerivedData/jake-and-bailey-fbutnsfforlfnpgkxyojdsdcaobc/Build/Intermediates/jake-and-bailey.build/Debug-iphonesimulator/jake-and-bailey.build/Objects-normal/i386/PrintAdventureMenuViewController.o
/Users/ethanraymond/Library/Developer/Xcode/DerivedData/jake-and-bailey-fbutnsfforlfnpgkxyojdsdcaobc/Build/Intermediates/jake-and-bailey.build/Debug-iphonesimulator/jake-and-bailey.build/Objects-normal/i386/AdventureTypeMenuViewController.o
duplicate symbol _OBJC_METACLASS_$_PrintAdventureMenuViewController in:
/Users/ethanraymond/Library/Developer/Xcode/DerivedData/jake-and-bailey-fbutnsfforlfnpgkxyojdsdcaobc/Build/Intermediates/jake-and-bailey.build/Debug-iphonesimulator/jake-and-bailey.build/Objects-normal/i386/PrintAdventureMenuViewController.o
/Users/ethanraymond/Library/Developer/Xcode/DerivedData/jake-and-bailey-fbutnsfforlfnpgkxyojdsdcaobc/Build/Intermediates/jake-and-bailey.build/Debug-iphonesimulator/jake-and-bailey.build/Objects-normal/i386/AdventureTypeMenuViewController.o
ld: 2 duplicate symbols for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
This was just after creating "PrintAdventureMenuViewController" class. So it is currently empty. "AdventureTypeMenuViewController" is not empty. It is populated with views other code.
答案 0 :(得分:0)
我的问题是在AdventureTypeMenuViewController.m文件中我使用了import语句......
#import "PrintAdventureMenuViewController.m"
而不是......
#import "PrintAdventureMenuViewController.h"