How to create static library from an existing framework in iOS?

感情迁移 提交于 2019-12-03 10:29:38

A *.framework is simply a package containing: the static library, headers, associated meta data. Copy and paste the .framework and extract the static *.a file and related header files.

Then it's simply a matter of using the MonoTouch btouch tool to bind the static library for use in your MonoTouch project. There is a great example of how to bind a native library to MonoTouch on Github. With guidance on targeting simulator + device and using the LinkWith attribute to embed the static library in a single *.dll:

Also, make sure to check out the btouch Reference documentation here:

Rename that binary file to Device.a. You can do that as the framework you mention is not done by Apple, hence it has to be a static library and not a dynamic one.

Make sure your project links that library (Device.a).

Include the headers in your project and reference them where appropriate.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!