- Get link
- X
- Other Apps
Unity3d : Xcode iOS Undefined symbols for architecture arm64 _OBJC_CLASS_$_ referenced from objc-class-ref in symbol(s) not found for architecture arm64
- Get link
- X
- Other Apps
Hi everyone, i love to do every mix stuff or cross technology, it's been a while for doing this kind of my hobby. The most unclear of any error i've given Xcode is the first place, why?, the error message and the description doesn't mean like that 100%. And this is the one i've blocked a day!!
If you familiar with create iOS plugin for Unity3d you can skip this thread but if you're newbie and get start for focus iOS and Unity3d, i will discuss the 3 point of Xcode that i've understanding by myself why this error always happen? why it's not gonna happen? i've capture the single image and circular red mark with number refer to below description.
I apologize for any reason that was wrong or doesn't mean like you know but the result is guarantee that work 100%, I've using Objective-C. This error happen when you've export iOS plugin then import to Unity and after export Unity project for Xcode then it come. Let's get start. Refer this error Undefined symbols for architecture arm64 _OBJC_CLASS_$_ referenced from objc-class-ref in symbol(s) not found for architecture arm64
1. DO, Get back to your plugin project, open Xcode, refer to above windows, tabs and any section. The compile sources, Important! this is the part you need to have added file.m and/or file.mm, don't remove the file you needed to compile for your plugin project.
2. DON'T, Add file.h here. why?, if you're working target 32 Bit only, it's fine, but if you want to target both 32 Bit and 64 Bit. It's occurs an error "Undefined symbols for architecture arm64 _OBJC_CLASS_$_ referenced from objc-class-ref in symbol(s) not found for architecture arm64", this Copy Files will export your file.h as include folder separate from file.a after exported. Yes, you can add separate folder included file.h and file.a into Unity3d without problem but when you export project then open with Xcode, file.h will refer error not support 64 Bit architecture. To make an error gone, you need to custom add file.h back to Copy Files, as manually every time when you export from Unity3d.
3. DO, Drag all relate file both file.m, file.mm and file.h into here, after you export file.a, it's not having separate include folder with file.h bcoz everything was compile for support both 32 Bit and 64 Bit into single file.a. After import single file.a to Unity3d, no error, after export Unity for iOS then open with Xcode, no error too.
This is the best way for you to working with create iOS plugin for Unity3d, useful for avoid 64 Bit error and don't needed to manually add file.h back to Copy files section in Xcode every time working with this platform. The single project not likely working in hell but think about 10!! plugins manually add file.h.
Ok, if you guys have any question just leave a comment or the other way that you've it's very very easy, please recommended as the comment too. i will update in this thread. See ya next thread :)
No Like, No Thumbs Up, No Bell, Just support me by click ads, thank you...
Comments


This comment has been removed by the author.
ReplyDelete