编译与theos的调整时SpringBoard头错误

时间:2014-01-03 08:26:43

标签: ios jailbreak tweak theos

我是jailbreak tweaks开发的新手,我正在使用theos来开发我的调整,但是当我使用make命令编译我的调整时遇到了一些问题。

基本上我用class-dump-z转储了所有IOS 7 SpringBoard标头,并将它们全部放在theos / include文件夹中。我意识到有一个名为XXUnknownSuperClass的类,当我编译调整时,我从该类中得到了一些错误。

/theos/include/Spring/SBUIAnimationController.h:8:9: error: 
      'XXUnknownSuperclass.h' file not found with <angled> include; use "quotes"
      instead
#import <XXUnknownSuperclass.h> // Unknown library
        ^~~~~~~~~~~~~~~~~~~~~~~
        "XXUnknownSuperclass.h"

/theos/include/Spring/XXUnknownSuperclass.h:14:12: error: 
      cannot find interface declaration for 'XXUnknownSuperclass'
@interface XXUnknownSuperclass (SBApplicationAdditions)

fatal error: too many errors emitted, stopping now [-ferror-limit=]

我的下一个问题是,当点击SBIconViewDelegate上的应用图标时,我可以挂钩SpringBoard来运行自定义方法吗?

非常感谢您的帮助!

1 个答案:

答案 0 :(得分:0)

无法直接使用类转储中的某些头文件。有一些常见错误,可以更改如下。

#import "NSObject.h"
-> 
#import <Foundation/NSObject.h>

@class CTPhoneNumber, NSArray, NSDate, NSDictionary, NSMutableArray, NSMutableDictionary, NSObject<CTMessageAddress, NSCopying>, NSString;
->
@class CTPhoneNumber, NSArray, NSDate, NSDictionary, NSMutableArray, NSMutableDictionary, NSObject<CTMessageAddress, NSCopying>, NSString;

NSObject<CTMessageAddress><NSCopying>
->
NSObject<CTMessageAddress,NSCopying>

对于您的问题,您可以删除有关“XXUnknownSuperclass”的声明或实现,或者有时删除“XXUnknownSuperclass”。

我更喜欢只声明当前项目的接口。您还可以在github.com上搜索“iOS标题”并下载其他人转储和修改的标题。

通常SBIconViewDelegate由SBIconController实现,您可以检查SBIconController的头文件和钩子相关的方法。