'how to solve this error : "Undefined symbols for architecture arm64"

I am getting this error continue, and there is no any error in the particular class. Can anyone tell me that how can i fix this error ?

Undefined symbols for architecture arm64: "_OBJC_CLASS_$_MYCLASS", referenced from: objc-class-ref in MYCLASS.o ld: symbol(s) not found for architecture arm64 clang: error: linker command failed with exit code 1 (use -v to see invocation)



Solution 1:[1]

You need to add necessary framework to your project. Check all third party party framework and search its required framework for support. For eg if you add google analytic then you need to add CoreData , Foundation etc framework. There is some framework is missing for which third party framework needs.

Solution 2:[2]

I think the error says you have not defined a member function of the class. In my case I forgot to define the constructor function and got this error. It usually depends on the compiler that you are using, for some compliers this error is not seen.

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Chanchal Warde
Solution 2