can anybody explain what are these packages that have extension (.a) that we may add it sometimes to xcode:
1) what exactly are those package开发者_运维问答s ?
2) how do they differ from other packages that have (.framework) extension ?
3) can I customize/change the code inside the (.a) package ?
thank you so much in advance.
They are a static library (or archive) generated by ar
. It contains one or more .o
object files, which contain compiled code and symbols needed for linking.
A .framework
contains both header files (.h
) specifying the interface, along with a .dylib
(a shared library).
A static library is already compiled into machine code - it is not easy to modify code in it. Unlike a shared library, a static library is designed to be linked by the linker - the object code will literally be copied into the destination file, whereas a shared library requires that it is present at runtime since only references are made.
精彩评论