How to solve ld: file is universal (2 slices) but does not contain a(n) armv7 slice: /Users/admin/Downloads/FaceDetect/libcv.a for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation) error in iphone opencv project
You need to change the architecture armv7.
and change the compiler GCC to LLVM.
Related
i'm building https://github.com/jvanakker/tvOSBrowser <- this browser project for Apple TV (4th gen), OS 11.3. Xcode 9.3 (stable) and i get following error:
ld: in
/System/Library/PrivateFrameworks/UIFoundation.framework/UIFoundation', missing required architecture arm64 in file
/System/Library/PrivateFrameworks/UIFoundation.framework/UIFoundation (2 slices) for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)
On AppleTV simulator it works quite well, but on actual hardware it fails...
I am using xcode 7.3 and using PubNub library. The build runs fine on simulator but fails while running on actual device.
Here is the error that I see :
ld: warning: ignoring file /Users/supercomputer/Documents/SitbaqApp/iPhoneDriverApp/CocoaLumberjack.framework/CocoaLumberjack, missing required architecture armv7 in file /Users/supercomputer/Documents/SitbaqApp/iPhoneDriverApp/CocoaLumberjack.framework/CocoaLumberjack (2 slices)
ld: warning: ignoring file /Users/supercomputer/Documents/SitbaqApp/iPhoneDriverApp/PubNub.framework/PubNub, missing required architecture armv7 in file /Users/supercomputer/Documents/SitbaqApp/iPhoneDriverApp/PubNub.framework/PubNub (2 slices)
Undefined symbols for architecture armv7:
"_OBJC_CLASS_$_PubNub", referenced from:
type metadata accessor for __ObjC.PubNub in AppDelegate.o
"_OBJC_CLASS_$_PNConfiguration", referenced from:
type metadata accessor for __ObjC.PNConfiguration in AppDelegate.o
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I have the $(inherited) flag in the OTHER LINKER FLAGS. I am not using cocoa pods for pubnub. It is framework drag and drop.
Now I am unable to run the app on actual device.
Any suggestions ?
I had same issue but when i use pod so i solved this issue. pod get automatic dependancy.
pod setup.
I have added adMob in a phonegap iOS project. It works fine in simulator But when I tried to build it in real device it shows me error and build failed.
errors message:
duplicate symbol _GAD_MD5 in:
/Users/prium/Documents/phonegap/projects/Diamond-mixer-iOS/GoogleAdmobiOS/llibGoogleAdMobAds.a(md5.o)
/Users/prium/Documents/phonegap/projects/Diamond-mixer-iOS/GoogleAdmobiOS/llibGoogleAdMobAds.a(gad_md5.o)
ld: 1 duplicate symbol for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Please help.
check out for Build settings-->architectures-->armv7 and armv7s. JUST put armv7
adding armv7 and armv7s to architecture should work
How can I get the libmysqlclient.a for armv7s so I can use it for my iPhone 5 to? Now I get this error:
ld: file is universal (6 slices) but does not contain a(n) armv7s slice: /Users/x/Documents/Xcode/Projecten/DirectMySQL/DirectMySQL/Objc_Mysql_iPhone_OSX/lib/libmysqlclient.a for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Thanks,
Daan!
Remove the armv7s from the architecture build settings. This is not necessary for anything other than high performance games on the iPhone 5 processor. Apple's default project include the armv7s but you don't need it.
This question already has answers here:
Closed 10 years ago.
Possible Duplicate:
linker command failed with exit code 1 xcode4.5
I am getting following error while i am archive my app for app store
ld: file is universal (3 slices) but does not contain a(n) armv7s slice: /Users/***************/l******/*****ppCircle.a for architecture armv7s
clang: error: linker command failed with exit code 1 (use -v to see invocation)
i tried to remove armv7s from my target then some new error start occuring.how i can resolve it
The problem is : you are using a library call : **ppCircle.a and this library was not compiled for armv7s.
Only two solutions :
1) If you have the library source code, you can try to compile it for armv7 AND armv7s
2) Instead of compiling your project with armv7s, use armv7 only (this can be changedin the project build settings)