Undefined symbols for architecture x86_64 when building software package - clang

Currently trying to build the software package, Neper. I have navigated many errors, but am currently stuck when it comes to this one.
In Terminal (mac), when I build using the make command, I get the following output:
[ 2%] Built target muparser
[ 7%] Built target ut
[ 13%] Built target orilib
[ 42%] Built target neut
[ 53%] Built target neper_v
[ 69%] Built target neper_m
[100%] Built target neper_t
[100%] Linking CXX executable neper
Undefined symbols for architecture x86_64:
"___kmpc_critical", referenced from:
_.omp_outlined. in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_3D1.c.o)
_nem_meshing_2D_face in libneper_m.a(nem_meshing_2D2.c.o)
_nem_mesh_2d_gmsh in libneper_m.a(nem_mesh_gmsh1.c.o)
_nem_meshing_2D_face_algo in libneper_m.a(nem_meshing_2D3.c.o)
net_polycomp_cells_updatecell(POLY, SEEDSET, nanoflann::KDTreeSingleIndexDynamicAdaptor<nanoflann::L2_Simple_Adaptor<double, NFCLOUD, double>, NFCLOUD, 3, unsigned long>**, int*, int, POLY**, TDYN*) in libneper_t.a(net_polycomp3.cpp.o)
net_polycomp_poly(POLY, SEEDSET, nanoflann::KDTreeSingleIndexDynamicAdaptor<nanoflann::L2_Simple_Adaptor<double, NFCLOUD, double>, NFCLOUD, 3, unsigned long>**, int*, int, POLY*, TDYN*) in libneper_t.a(net_polycomp_poly1.cpp.o)
...
"___kmpc_dispatch_init_4", referenced from:
_.omp_outlined. in libneper_t.a(net_utils1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined..4 in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_3D1.c.o)
_.omp_outlined. in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..2 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..3 in libneper_t.a(net_polycomp2.cpp.o)
...
"___kmpc_dispatch_init_4u", referenced from:
_.omp_outlined..1 in libneper_t.a(net_ori_uniform4.cpp.o)
"___kmpc_dispatch_next_4", referenced from:
_.omp_outlined. in libneper_t.a(net_utils1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined..4 in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_3D1.c.o)
_.omp_outlined. in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..2 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..3 in libneper_t.a(net_polycomp2.cpp.o)
...
"___kmpc_dispatch_next_4u", referenced from:
_.omp_outlined..1 in libneper_t.a(net_ori_uniform4.cpp.o)
"___kmpc_end_critical", referenced from:
_.omp_outlined. in libneper_m.a(nem_meshing_2D1.c.o)
_.omp_outlined. in libneper_m.a(nem_meshing_3D1.c.o)
_nem_meshing_2D_face in libneper_m.a(nem_meshing_2D2.c.o)
_nem_mesh_2d_gmsh in libneper_m.a(nem_mesh_gmsh1.c.o)
_nem_meshing_2D_face_algo in libneper_m.a(nem_meshing_2D3.c.o)
net_polycomp_cells_updatecell(POLY, SEEDSET, nanoflann::KDTreeSingleIndexDynamicAdaptor<nanoflann::L2_Simple_Adaptor<double, NFCLOUD, double>, NFCLOUD, 3, unsigned long>**, int*, int, POLY**, TDYN*) in libneper_t.a(net_polycomp3.cpp.o)
net_polycomp_poly(POLY, SEEDSET, nanoflann::KDTreeSingleIndexDynamicAdaptor<nanoflann::L2_Simple_Adaptor<double, NFCLOUD, double>, NFCLOUD, 3, unsigned long>**, int*, int, POLY*, TDYN*) in libneper_t.a(net_polycomp_poly1.cpp.o)
...
"___kmpc_for_static_fini", referenced from:
_.omp_outlined. in libneut.a(neut_tesr_op1.c.o)
_.omp_outlined. in libneper_v.a(nev_data_utils1.c.o)
_.omp_outlined..51 in libneper_v.a(nev_data_utils1.c.o)
_.omp_outlined. in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..2 in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..3 in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..4 in libneper_v.a(nev_print_tesr1.c.o)
...
"___kmpc_for_static_init_4", referenced from:
_.omp_outlined. in libneut.a(neut_tesr_op1.c.o)
_.omp_outlined. in libneper_v.a(nev_data_utils1.c.o)
_.omp_outlined..51 in libneper_v.a(nev_data_utils1.c.o)
_.omp_outlined. in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..2 in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..3 in libneper_v.a(nev_print_tesr1.c.o)
_.omp_outlined..4 in libneper_v.a(nev_print_tesr1.c.o)
...
"___kmpc_for_static_init_4u", referenced from:
_.omp_outlined. in libneper_t.a(net_ori_uniform3.cpp.o)
_.omp_outlined..1 in libneper_t.a(net_ori_uniform3.cpp.o)
_.omp_outlined..2 in libneper_t.a(net_ori_uniform3.cpp.o)
_.omp_outlined. in libneper_t.a(net_ori_uniform4.cpp.o)
_.omp_outlined..3 in libneper_t.a(net_ori_uniform4.cpp.o)
_.omp_outlined..4 in libneper_t.a(net_ori_uniform4.cpp.o)
"___kmpc_fork_call", referenced from:
_main in neper.c.o
_neper_head in neper.c.o
_net_tess_tesr in libneper_t.a(net_utils1.c.o)
_neut_tesr_rotate in libneut.a(neut_tesr_op1.c.o)
_nem_meshing_2D in libneper_m.a(nem_meshing_2D1.c.o)
_nem_meshing_3D in libneper_m.a(nem_meshing_3D1.c.o)
_nev_data_id_colour in libneper_v.a(nev_data_utils1.c.o)
...
"___kmpc_global_thread_num", referenced from:
_nem_meshing_2D_face in libneper_m.a(nem_meshing_2D2.c.o)
_.omp_outlined. in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..2 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..3 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..4 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..5 in libneper_t.a(net_polycomp2.cpp.o)
_.omp_outlined..6 in libneper_t.a(net_polycomp2.cpp.o)
...
"_omp_get_num_threads", referenced from:
_.omp_outlined. in neper.c.o
"_omp_get_thread_num", referenced from:
_.omp_outlined. in neper.c.o
_nem_mesh_2d_gmsh in libneper_m.a(nem_mesh_gmsh1.c.o)
_nem_mesh_3d_gmsh in libneper_m.a(nem_mesh_gmsh1.c.o)
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
make[2]: *** [neper] Error 1
make[1]: *** [CMakeFiles/neper.dir/all] Error 2
make: *** [all] Error 2
It seems like it built all the way, but there is some mismatch with these kmpc symbols. From what I've read this seems like an issue on the compiler side (that could be wrong), but I have yet to find any solutions. Any idea on how to fix this error?

This looks similar to this intel question.
I suspect that you need to link with libomp (but that's just a guess)

Check if you have gcc-x, where x is a number. I saw several examples using gcc-8 but that won't work as I had gcc-10.
What I did was go to the terminal, wrote down gcc-, then tab so show the options I had. When using gcc-10 I was able to run openMP without problems
I did brew install gcc and brew install libomp.
cheers

Came across this when doing some search for the same issue. I'm sure you've already had this sorted out but just in case there are other people looking for this. Essentially the gcc comes with mac os is a fake one, it's really apple's clang with the alias "gcc". So the solution is to tell cmake to use the real gcc compilers by running the command:
$ cmake .. -DCMAKE_C_COMPILER=gcc-11 -DCMAKE_CXX_COMPILER=g++-11
I have gcc 11 installed, so you should replace 11 by whatever version you have there. If you don't have a real version of gcc, just do
$ brew install gcc

Related

Undefined symbols for architecture arm64, it seems just randomly happened to some third party framework using cocoapods

What happened
I used Cocoapods to manage some third-party frameworks
I used some private spec repos
More than one private repos have dependency on same third-party pods
After a modification of dependency structure,I build my workspace, it shows these errors:
Undefined symbols for architecture arm64:
"_OBJC_METACLASS_$_UIView", referenced from:
_OBJC_METACLASS_$_iCarousel in iCarousel.o
"_OBJC_CLASS_$_UIButton", referenced from:
objc-class-ref in iCarousel.o
"_OBJC_CLASS_$_UIScrollView", referenced from:
objc-class-ref in iCarousel.o
"_OBJC_CLASS_$_UIScreen", referenced from:
objc-class-ref in iCarousel.o
"_OBJC_CLASS_$_UITapGestureRecognizer", referenced from:
objc-class-ref in iCarousel.o
"_OBJC_CLASS_$_UIView", referenced from:
objc-class-ref in iCarousel.o
_OBJC_CLASS_$_iCarousel in iCarousel.o
"_OBJC_CLASS_$_UIBarButtonItem", referenced from:
objc-class-ref in iCarousel.o
"_UITrackingRunLoopMode", referenced from:
-[iCarousel startAnimation] in iCarousel.o
"_CGSizeZero", referenced from:
-[iCarousel setUp] in iCarousel.o
"_OBJC_CLASS_$_UIPanGestureRecognizer", referenced from:
objc-class-ref in iCarousel.o
"_UIAccessibilityTraitAllowsDirectInteraction", referenced from:
-[iCarousel setUp] in iCarousel.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
What I've done to try to solve this problem?(none of them works)
Deleted Xcode caches by rm -rf ~/Library/Developer/Xcode/DerivedData/
Deleted Cocoapods caches by $ rm -rf "${HOME}/Library/Caches/CocoaPods" $rm -rf "pwd/Pods/" $pod update
Update the Xcode version to 12.0.1
Oh no, same errors!
What I've done next...
I decided to go the hard way, so I add those things to my Podfile:
if target.name == "iCarousel"
config.build_settings['OTHER_LDFLAGS'] ||= ['$(inherited)']
config.build_settings['OTHER_LDFLAGS'] << '-framework "UIKit"'
config.build_settings['OTHER_LDFLAGS'] << '-framework "CoreGraphics"'
end
Then, pod install
Build my project...
Good news! nothing to do with iCarousel! Bad news, same old errors happened to another pod: PomeloPush
Undefined symbols for architecture arm64:
"_SCNetworkReachabilitySetDispatchQueue", referenced from:
-[PomeloReachability startNotifier] in PomeloReachability.o
-[PomeloReachability stopNotifier] in PomeloReachability.o
"_SCError", referenced from:
-[PomeloReachability startNotifier] in PomeloReachability.o
"_SCErrorString", referenced from:
-[PomeloReachability startNotifier] in PomeloReachability.o
"_SCNetworkReachabilityGetFlags", referenced from:
-[PomeloReachability isReachable] in PomeloReachability.o
-[PomeloReachability isReachableViaWWAN] in PomeloReachability.o
-[PomeloReachability isReachableViaWiFi] in PomeloReachability.o
-[PomeloReachability connectionRequired] in PomeloReachability.o
-[PomeloReachability isConnectionOnDemand] in PomeloReachability.o
-[PomeloReachability isInterventionRequired] in PomeloReachability.o
-[PomeloReachability reachabilityFlags] in PomeloReachability.o
...
"_SCNetworkReachabilitySetCallback", referenced from:
-[PomeloReachability startNotifier] in PomeloReachability.o
-[PomeloReachability stopNotifier] in PomeloReachability.o
"_SCNetworkReachabilityCreateWithAddress", referenced from:
+[PomeloReachability reachabilityWithAddress:] in PomeloReachability.o
"_CFHostStartInfoResolution", referenced from:
+[PomeloHostRequest nslookup:] in PomeloHostRequest.o
"_OBJC_CLASS_$_UIDevice", referenced from:
objc-class-ref in PomeloClient.o
"_SCNetworkReachabilityCreateWithName", referenced from:
+[PomeloReachability reachabilityWithHostname:] in PomeloReachability.o
"_CFHostCreateWithName", referenced from:
+[PomeloHostRequest nslookup:] in PomeloHostRequest.o
"_CFHostGetAddressing", referenced from:
+[PomeloHostRequest nslookup:] in PomeloHostRequest.o
"_OBJC_CLASS_$_UIPasteboard", referenced from:
objc-class-ref in Pomelo_OpenUDID.o
"_UIApplicationDidEnterBackgroundNotification", referenced from:
-[PomeloClient addNotification] in PomeloClient.o
"_UIApplicationWillEnterForegroundNotification", referenced from:
-[PomeloClient addNotification] in PomeloClient.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Then I added some similar code in Podfile
Then pod install, build
Oh, a similar error happened to another pod:
Undefined symbols for architecture arm64:
"_OBJC_CLASS_$_UIViewController", referenced from:
__OBJC_$_CATEGORY_UIViewController_$_KeyboardAnimation in UIViewController+KeyboardAnimation.o
"_UIKeyboardAnimationDurationUserInfoKey", referenced from:
-[UIViewController(KeyboardAnimation) getDurationFromNotification:] in UIViewController+KeyboardAnimation.o
"_UIKeyboardAnimationCurveUserInfoKey", referenced from:
-[UIViewController(KeyboardAnimation) getAnimationCurveFromNotification:] in UIViewController+KeyboardAnimation.o
"_UIKeyboardFrameEndUserInfoKey", referenced from:
-[UIViewController(KeyboardAnimation) getKeyboardRectFromNotification:] in UIViewController+KeyboardAnimation.o
"_UIKeyboardWillChangeFrameNotification", referenced from:
-[UIViewController(KeyboardAnimation) an_subscribeKeyboardFrameChangesWithAnimations:] in UIViewController+KeyboardAnimation.o
-[UIViewController(KeyboardAnimation) an_unsubscribeKeyboardFrameChanges] in UIViewController+KeyboardAnimation.o
"_UIKeyboardWillShowNotification", referenced from:
-[UIViewController(KeyboardAnimation) an_subscribeKeyboardWithBeforeAnimations:animations:completion:] in UIViewController+KeyboardAnimation.o
-[UIViewController(KeyboardAnimation) an_unsubscribeKeyboard] in UIViewController+KeyboardAnimation.o
"_OBJC_CLASS_$_UIView", referenced from:
objc-class-ref in UIViewController+KeyboardAnimation.o
"_UIKeyboardWillHideNotification", referenced from:
-[UIViewController(KeyboardAnimation) an_subscribeKeyboardWithBeforeAnimations:animations:completion:] in UIViewController+KeyboardAnimation.o
-[UIViewController(KeyboardAnimation) an_unsubscribeKeyboard] in UIViewController+KeyboardAnimation.o
ld: symbol(s) not found for architecture arm64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
for now, it had happened on pop, AFNetworking, SDWebImage, iCarousel, MJRefresh, and so on...
Any suggestions could help would be greatly appreciated!! I've stuck on this for a week...
By looking out your observation you can try out the following suggestion:
Check if your cocoapods are updated to latest version.
remove all pods using pod deintegrate.
check the dependencies of pods and try to install one by one. pod install.
also check the support of libraries to your swift version.
if both libraries have same code or extension it will give you the error.
Also could be helpful to remove all pods first:
pod deintegrate
then
pod install

How to solve "undefined symbols for architecture x86_64" and "linker command failed with exit code 1" in xcode?

I am trying to build a project in xcode and I get the following errors:
Undefined symbols for architecture x86_64:
"_OBJC_CLASS_$_Zoom", referenced from:
objc-class-ref in ZoomConnectedNetworking.o
objc-class-ref in ZoomViewController.o
objc-class-ref in RNAppBridge-843d3738eaf9ad6c9a88b86d7afb070208b29a596e7ec9fd5f0c00a394da72ff.o
"_OBJC_CLASS_$_ZoomCancelButtonCustomization", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_OBJC_CLASS_$_ZoomCustomization", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_OBJC_CLASS_$_ZoomFeedbackCustomization", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_OBJC_CLASS_$_ZoomFrameCustomization", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_OBJC_CLASS_$_ZoomInstructionsImages", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_OBJC_CLASS_$_ZoomOvalCustomization", referenced from:
objc-class-ref in ZoomConnectedConfig.o
"_construct_single_private_key", referenced from:
static pingpongRN.GothamClient.getSinglePrivateKey(x1: Swift.String, x2: Swift.String) -> Swift.String? in GothamClient.o
"_decrypt_party_one_master_key", referenced from:
static pingpongRN.GothamClient.decryptPartyOneMasterKey(client_share: pingpongRN.MasterKey2, encrypted_server_share: Swift.String, private_key: Swift.String) -> Swift.String? in GothamClient.o
"_get_child_mk1", referenced from:
static pingpongRN.GothamClient.getChildServerShare(server_share_str: Swift.String, x_pos: Swift.String, y_pos: Swift.String) -> Swift.String? in GothamClient.o
"_get_child_mk2", referenced from:
static pingpongRN.GothamClient.getChildClientShare(client_share_str: Swift.String, x_pos: Swift.String, y_pos: Swift.String) -> pingpongRN.MasterKey2? in GothamClient.o
"_get_client_master_key", referenced from:
static pingpongRN.GothamClient.generate_master_key2(gothamEndpoint: Swift.String) -> (pingpongRN.MasterKey1?, pingpongRN.MasterKey2?) in GothamClient.o
"_sign_message", referenced from:
static pingpongRN.GothamClient.sign(gothamEndpoint: Swift.String, message_hex: Swift.String, x_pos: Swift.String, y_pos: Swift.String, master_key_2: pingpongRN.MasterKey2, master_key1_id: Swift.String) -> pingpongRN.Signature? in GothamClient.o
ld: symbol(s) not found for architecture x86_64
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I tried cleaning and I have read about looking at the linking but it seems like all of the libraries and frameworks I need are in place.
Any reason why this is happening?
There several possible reasons:
You linked the library that has no architectures for Simulator ( seems that you're building for simulator ) - to check that you can simply thought terminal:
lipo -info LIBRARY_OR_FRAMEWORK_FILE (it will show you all compatible architectures)
You completely not linking library:
To check that just more to "Build Phase" tab and look at "Link Binary with Libraries" phase

Best practices for ios project use unity3d

We ios project use unity3d, but the unity3d project is in developing, and they send we new unity3d project every day, we needs to export to ios project every day, and we move our current ios project to the new exported ios project by unity3d. How do you guys do about this, we try to build the u3d ios project to static lib, we build success but use the static lib have many problems, some like:
Undefined symbols for architecture armv7:
"UnityKeyboard_GetText(std::string*)", referenced from:
KeyboardOnScreen::getText() const in libiPhone-lib.a(iPhoneKeyboard.o)
"UnityAD_DestroyInterstitial(void*)", referenced from:
ADInterstitialAd_CUSTOM_Native_DestroyInterstitial(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_InterstitialAvailable()", referenced from:
ADInterstitialAd_CUSTOM_Native_InterstitialAvailable() in libiPhone-lib.a(iAD.o)
"UnityAD_ReloadInterstitial(void*)", referenced from:
ADInterstitialAd_CUSTOM_Native_ReloadInterstitial(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_ShowInterstitial(void*)", referenced from:
ADInterstitialAd_CUSTOM_Native_ShowInterstitial(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_CreateInterstitial(bool)", referenced from:
ADInterstitialAd_CUSTOM_Native_CreateInterstitial(short) in libiPhone-lib.a(iAD.o)
"UnityAD_ShowBanner(void*, bool)", referenced from:
ADBannerView_CUSTOM_Native_ShowBanner(void*, short) in libiPhone-lib.a(iAD.o)
"UnityAD_BannerAdLoaded(void*)", referenced from:
ADBannerView_CUSTOM_Native_BannerAdLoaded(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_InterstitialAdLoaded(void*)", referenced from:
ADInterstitialAd_CUSTOM_Native_InterstitialAdLoaded(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_BannerPosition(void*, float*, float*)", referenced from:
ADBannerView_CUSTOM_Native_BannerPosition(void*, Vector2f*) in libiPhone-lib.a(iAD.o)
"UnityAD_DestroyBanner(void*)", referenced from:
ADBannerView_CUSTOM_Native_DestroyBanner(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_LayoutBanner(void*, int)", referenced from:
ADBannerView_CUSTOM_Native_LayoutBanner(void*, int) in libiPhone-lib.a(iAD.o)
"UnityAD_BannerSize(void*, float*, float*)", referenced from:
ADBannerView_CUSTOM_Native_BannerSize(void*, Vector2f*) in libiPhone-lib.a(iAD.o)
"UnityAD_MoveBanner(void*, float, float)", referenced from:
ADBannerView_CUSTOM_INTERNAL_CALL_Native_MoveBanner(void*, Vector2f const&) in libiPhone-lib.a(iAD.o)
"UnityAD_BannerTypeAvailable(int)", referenced from:
ADBannerView_CUSTOM_Native_BannerTypeAvailable(int) in libiPhone-lib.a(iAD.o)
"UnityAD_BannerAdVisible(void*)", referenced from:
ADBannerView_CUSTOM_Native_BannerAdVisible(void*) in libiPhone-lib.a(iAD.o)
"UnityAD_CreateBanner(int, int)", referenced from:
ADBannerView_CUSTOM_Native_CreateBanner(int, int) in libiPhone-lib.a(iAD.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
There is a "libiPhone-lib.a" file in "Libraries" directory after you build (by unity3d).
check if the "libiPhone-lib.a" in your "Link Binary With Libraries" . if not click "+" ->
"Add other..." -> "Libraries" select "libiPhone-lib.a" .
i fixed my errors by this .

Using custom cocoapod gives compile errors (Undefined symbols for architecture armv7:)

I built my own pod for my own internal usage. The pod spec lint worked fine but when I tried to actually use it, it gave me the following compile errors:
Undefined symbols for architecture armv7:
"___gxx_personality_sj0", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"vtable for __cxxabiv1::__class_type_info", referenced from:
typeinfo for CAXException in libPods.a(ExtAudioFileConvert.o)
NOTE: a missing vtable usually means the first non-inline virtual member function has no definition.
"std::__throw_bad_alloc()", referenced from:
std::_Vector_base<AudioBufferList*, std::allocator<AudioBufferList*> >::_M_allocate(unsigned long) in libPods.a(ExtAudioFileConvert.o)
"CAStreamBasicDescription::CAStreamBasicDescription()", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"___cxa_allocate_exception", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"___cxa_throw", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"operator new[](unsigned long)", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"___cxa_begin_catch", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"operator new(unsigned long)", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
std::_Vector_base<AudioBufferList*, std::allocator<AudioBufferList*> >::_M_allocate(unsigned long) in libPods.a(ExtAudioFileConvert.o)
"std::__throw_length_error(char const*)", referenced from:
std::vector<AudioBufferList*, std::allocator<AudioBufferList*> >::_M_insert_aux(__gnu_cxx::__normal_iterator<AudioBufferList**, std::vector<AudioBufferList*, std::allocator<AudioBufferList*> > >, AudioBufferList* const&) in libPods.a(ExtAudioFileConvert.o)
"___cxa_free_exception", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"_OBJC_CLASS_$_MPMusicPlayerController", referenced from:
objc-class-ref in libPods.a(AudioManager.o)
"___cxa_end_catch", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"std::terminate()", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
"operator delete(void*)", referenced from:
_GetConvertedData in libPods.a(ExtAudioFileConvert.o)
std::vector<AudioBufferList*, std::allocator<AudioBufferList*> >::_M_insert_aux(__gnu_cxx::__normal_iterator<AudioBufferList**, std::vector<AudioBufferList*, std::allocator<AudioBufferList*> > >, AudioBufferList* const&) in libPods.a(ExtAudioFileConvert.o)
ld: symbol(s) not found for architecture armv7
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I suspect the frameworks are not set properly in the podspec as this is my first pod to write and I probably have a few mistakes in there.
Thanks in advance.
Officially answering the question I posted. I needed to do the following to fix it:
Link the C++ standard library: (Thanks to #H2CO3)
add s.library = 'stdc++' to the podspec
Link MediaPlayer framework: (Thanks to #H2CO3)
add s.frameworks = 'MediaPlayer' to the podspec
Issue with CAStreamBasicDescription was fixed by following the answer of: Trouble linking Tim Bolstad's Core Audio Example

Error linking OpenCV and Tesseract

I'm trying to using both OpenCV and Tesseract in my iPhone app.
I have no problem working with either one of them - all is compiled and linked perfectly.
But when I'm trying to work with both of them it gives me link errors:
Undefined symbols for architecture i386:
"cv::_OutputArray::_OutputArray(cv::Mat&)", referenced from:
-[BTLOpenCVCameraViewController processImage:] in BTLOpenCVCameraViewController.o
"cv::_OutputArray::~_OutputArray()", referenced from:
-[BTLOpenCVCameraViewController processImage:] in BTLOpenCVCameraViewController.o
"cv::Mat::deallocate()", referenced from:
cv::Mat::release() in BTLOpenCVCameraViewController.o
"cv::Mat::Mat(cv::Mat const&, cv::Rect_<int> const&)", referenced from:
-[BTLOpenCVCameraViewController processImage:] in BTLOpenCVCameraViewController.o
"cv::fastFree(void*)", referenced from:
cv::Mat::~Mat() in BTLOpenCVCameraViewController.o
"cv::Mat::copyTo(cv::_OutputArray const&) const", referenced from:
-[BTLOpenCVCameraViewController processImage:] in BTLOpenCVCameraViewController.o
ld: symbol(s) not found for architecture i386
clang: error: linker command failed with exit code 1 (use -v to see invocation)
I'm running iOS6.1, C++ Standard Library is set to: "Compiler Default"
Architecture is set to: armv7.
ANy ideas??

Resources