我知道,这个问题已被讨论了数百万次,但没有一个答案对我有用。我现在疯了,我花了几天时间来解决它,但没有运气:(
我正在使用Cordova,一旦我创建了一个新类,然后将其导入CDVViewController.h
我的问题就开始了,整个应用程序都失败了。我正在使用Xcode 6.1和Cordova 4.1.2
看起来我无法创建新类并导入它或在cordova中使用它?
在尝试构建应用时,我一直收到以下错误:
我已经尝试过我能想到的所有内容,例如
我真的不知道出了什么问题以及如何解决它。
有人可以帮助我吗?
编辑:这是我正在尝试添加的课程MyNewFaultyViewController
的日志。
Ld /Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/myProject normal armv7
cd /Applications/XAMPP/xamppfiles/htdocs/ionicTest/newFPStack/financialPack/platforms/ios
export IPHONEOS_DEPLOYMENT_TARGET=8.1
export PATH="/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.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 armv7 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS8.1.sdk -L/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Products/Debug-iphoneos -F/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Products/Debug-iphoneos -filelist /Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/myProject.LinkFileList -dead_strip -weak_framework CoreFoundation -weak_framework UIKit -weak_framework AVFoundation -weak_framework CoreMedia -weak-lSystem -ObjC -fobjc-arc -fobjc-link-runtime -miphoneos-version-min=8.1 -framework AssetsLibrary /Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Products/Debug-iphoneos/libCordova.a -framework CoreGraphics -framework MobileCoreServices -framework QuickLook -Xlinker -dependency_info -Xlinker /Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/myProject_dependency_info.dat -o /Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/myProject
duplicate symbol _OBJC_CLASS_$_MyNewFaultyViewController in:
/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/MyNewFaultyViewController-1749AE3BBC66FA7A.o
/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Products/Debug-iphoneos/libCordova.a(MyNewFaultyViewController.o)
duplicate symbol _OBJC_METACLASS_$_MyNewFaultyViewController in:
/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Intermediates/myProject.build/Debug-iphoneos/myProject.build/Objects-normal/armv7/MyNewFaultyViewController-1749AE3BBC66FA7A.o
/Users/myUserName/Library/Developer/Xcode/DerivedData/myProject-dvlfakeuyafwuqgwlpxkelyypfib/Build/Products/Debug-iphoneos/libCordova.a(MyNewFaultyViewController.o)
ld: 2 duplicate symbols for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)