ios \u4e0a\u67b6\u6253\u5305 loader<\/a>\u5f62\u6210\u4e00\u4e2aFramework\u8fdb\u884c\u7edf\u4e00\u7ba1\u7406\uff0c\u8fd9\u6837\u53ef\u4ee5\u7b80\u5316\u5f00\u53d1\u6d41\u7a0b\uff0c\u907f\u514d\u91cd\u590d\u52b3\u52a8\u3002<\/p>\n3. \u7f16\u8bd1iOS Framework<\/p>\n
\u5728\u5b8c\u6210Framework\u7684\u5f00\u53d1\u540e\uff0c\u9700\u8981\u8fdb\u884c\u7f16\u8bd1\uff0c\u4ee5\u751f\u6210Framework\u7684\u9759\u6001\u5e93\u3002\u9996\u5148\uff0c\u9700\u8981\u9009\u62e9Framework\u9879\u76ee\u7684Target\uff0c\u70b9\u51fbBuild Phases -> Link Binary With Libraries -> Add Other\uff0c\u9009\u62e9\u751f\u6210\u7684\u9759\u6001\u5e93\u6587\u4ef6\u8fdb\u884c\u5bfc\u5165\u3002<\/p>\n
4. \u6253\u5305iOS Framework<\/p>\n
\u5728\u7f16\u8bd1\u751f\u6210\u4e86iOS Framework\u9759\u6001\u5e93\u540e\uff0c\u9700\u8981\u628aFramework\u6253\u5305\u6210.framework\u683c\u5f0f\u65b9\u4fbf\u5176\u4ed6\u9879\u76ee\u53ef\u4ee5\u5bfc\u5165\u4f7f\u7528\u3002\u70b9\u51fb\u9879\u76ee\u5de6\u4fa7\u8fd0\u884c\u83dc\u5355\uff0c\u9009\u62e9\u6a21\u62df\u5668\u6216\u8005\u771f\u673a\uff0c\u5728Xcode\u8f93\u51fa\u9762\u677f\u4e2d\u53ef\u4ee5\u770b\u5230Framework\u7684\u8def\u5f84\uff0c\u5c06\u8def\u5f84\u8f93\u5165\u7ec8\u7aef\u547d\u4ee4\u884c\u4e2d\uff0c\u8f93\u5165\u547d\u4ee4\uff1a<\/p>\n
lipo -create Framework\u8def\u5f84\/Release-iphonesimulator\/Framework.framework\/Framework Framework\u8def\u5f84\/Release-iphoneos\/Framework.framework\/Framework -output Framework\u8def\u5f84\/Framework<\/p>\n
\u8fd9\u6837\u6211\u4eec\u5c31\u53ef\u4ee5\u751f\u6210\u4e00\u4e2aiOS Framework\u7684\u53ef\u7528\u9759\u6001\u5e93\u4e86\u3002<\/p>\n
5. \u5bfc\u5165iOS Framework<\/p>\n
\u5728\u5176\u4ed6\u9879\u76ee\u4e2d\u9700\u8981\u4f7f\u7528\u8be5iOS Framework\u65f6\uff0c\u5148\u5c06\u5176\u5bfc\u5165\u5230\u65b0\u9879\u76ee\u4e2d\u3002\u5728Xcode\u4e2d\uff0c\u9009\u62e9\u9700\u8981\u5bfc\u5165Framework\u7684Target\uff0c\u70b9\u51fbBuild Phases -> Link Binary With Libraries -> Add Other\uff0c\u5f15\u5165\u6211\u4eec\u521a\u624d\u6253\u5305\u597d\u7684.framework\u6587\u4ef6\u3002<\/p>\n
6. \u94fe\u63a5iOS Framework<\/p>\n
\u5728\u4f7f\u7528\u5bfc\u5165\u7684Framework\u65f6\uff0c\u5728\u9700\u8981\u7528\u5230\u7684\u6587\u4ef6\u4e2d\uff0c\u9700\u8981\u5f15\u5165\u76f8\u5e94\u7684\u5934\u6587\u4ef6\uff0c\u4ee5\u4f7f\u7528Framework\u4e2d\u7684\u7c7b\u548c\u65b9\u6cd5\u3002\u540c\u65f6\uff0c\u8fd8\u9700\u8981\u5728\u9879\u76ee\u7684Build Settings\u4e2d\u627e\u5230\u201cOther Linker Flags\u201d\u9879\uff0c\u6dfb\u52a0\u201c-ObjC\u201d\u6807\u5fd7\uff0c\u4fdd\u8bc1Framework\u80fd\u6b63\u786e\u7684\u94fe\u63a5\u3002<\/p>\n
\u4e09\u3001\u603b\u7ed3<\/p>\n
\u901a\u8fc7\u4ee5\u4e0a\u6b65\u9aa4\u7684\u4ecb\u7ecd\uff0c\u6211\u4eec\u53ef\u4ee5\u4e86\u89e3\u5230\u6253\u5305iOS Framework\u7684\u8fc7\u7a0b\uff0c\u9700\u8981\u6ce8\u610f\u7684\u662f\uff1aFramework\u6587\u4ef6\u4e0d\u80fd\u88ab\u5171\u4eab\u7ed9\u5916\u90e8\u7684\u5176\u4ed6app\u4f7f\u7528\u3002\u901a\u8fc7\u6253\u5305Framework\uff0c\u53ef\u4ee5\u5c06\u4ee3\u7801\u7528\u4e8e\u591a\u4e2a\u9879\u76ee\uff0c\u5927\u5927\u63d0\u9ad8\u4e86\u4ee3\u7801\u7684\u590d\u7528\u6027\uff0c\u540c\u65f6\u4e5f\u66f4\u5bb9\u6613\u7ef4\u62a4\u548c\u7ba1\u7406\u4ee3\u7801\u3002\u6240\u4ee5\u5bf9\u4e8e\u591a\u4e2a\u9879\u76ee\u4e2d\u516c\u7528\u7684\u90e8\u5206\uff0c\u6211\u4eec\u53ef\u4ee5\u9009\u62e9\u6253\u5305\u6210Framework\u7684\u5f62\u5f0f\u3002<\/p>\n","protected":false},"excerpt":{"rendered":"
iOS framework\u662fiOS\u5f00\u53d1\u4e2d\u5e38\u7528\u7684\u4e00\u79cd\u5f00\u53d1\u65b9\u5f0f\uff0c\u53ef\u4ee5\u5c06\u4e00\u4e2a\u6216\u591a\u4e2a\u7f16\u5199\u597d\u7684OC\u6216Swift\u6587\u4ef6\u548c\u8d44\u6e90\u6253\u5305\u6210\u4e00\u4e2a\u9759\u6001\u5e93\uff0c\u65b9\u4fbf\u5728\u591a\u4e2a\u9879\u76ee\u4e2d\u590d\u7528\uff0c\u63d0\u9ad8\u4ee3\u7801\u7684\u590d\u7528\u6027\u3002\u672c\u6587\u5c06\u5bf9iOS framewo<\/p>\n","protected":false},"author":4,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[4],"tags":[9860,11707,29,1006,23],"topic":[],"class_list":{"0":"post-6429","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-appkf","7":"tag-ios","9":"tag-29","10":"tag-1006","11":"tag-23"},"_links":{"self":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/6429","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/users\/4"}],"replies":[{"embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/comments?post=6429"}],"version-history":[{"count":0,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/posts\/6429\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/media?parent=6429"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/categories?post=6429"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/tags?post=6429"},{"taxonomy":"topic","embeddable":true,"href":"https:\/\/www.yimenyun.cn\/emen\/wp-json\/wp\/v2\/topic?post=6429"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}