美文网首页
iOS 逆向 新版Theos error: cannot fin

iOS 逆向 新版Theos error: cannot fin

作者: 加盐白咖啡 | 来源:发表于2021-01-29 17:51 被阅读0次

最近发现更新了最新的Theos,编译旧项目报错了,例如下面的错误:
Tweak.xm:51:26: error: cannot find interface declaration for 'UIView', superclass of 'UIStatusBar' @interface UIStatusBar : UIView

解决办法(特此记录一下方便他人搜索):

在文件头部引用 @import UIKit; 就OK了,别少了分号,少了也没关系,反正make的时候会提示

此外,MSHookIvar在使用.x时需要C++(.mm或.xm),您可以将文件重命名为.xm并用新的文件名更新Makefile,或者考虑使用KVO ([self valueForKey:@"_pwdView"])

相关文章

网友评论

      本文标题:iOS 逆向 新版Theos error: cannot fin

      本文链接:https://www.haomeiwen.com/subject/fwfctltx.html