【问题标题】:Theos fails to compile tweak after adding preference bundleTheos 在添加首选项包后无法编译调整
【发布时间】:2013-03-20 04:13:24
【问题描述】:

我正在尝试将首选项包添加到我正在构建的调整中。我关注了this tutorial 的部分,他们在其中添加了首选项包。在我尝试添加首选项包后,我的调整无法编译并出现以下错误:

Making all for tweak MyTweak...
 Preprocessing Tweak.xm...
 Compiling Tweak.xm...
 Linking tweak MyTweak...
 Stripping MyTweak...
 Signing MyTweak...
Making all in prefs...
Making all for bundle prefs...
 Copying resource directories into the bundle wrapper...
 Compiling prefs.mm...
cc1objplus: warnings being treated as errors
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSListController.h:9,
                 from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSLocaleController.h:8,
                 from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/Preferences.h:9,
                 from prefs.mm:1:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSViewController.h:47: warning: property ‘specifier’ type does not match protocol ‘PSController’ property type
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSViewController.h:47: warning: property ‘rootController’ type does not match protocol ‘PSController’ property type
In file included from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSSetupController.h:7,
                 from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSInternationalLanguageSetupController.h:7,
                 from /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/Preferences.h:24,
                 from prefs.mm:1:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS6.1.sdk/System/Library/PrivateFrameworks/Preferences.framework/Headers/PSRootController.h:71: warning: property ‘specifier’ type does not match protocol ‘PSController’ property type
make[3]: *** [obj/prefs.mm.ade1d157.o] Error 1
make[2]: *** [internal-bundle-all_] Error 2
make[1]: *** [prefs.all.bundle.variables] Error 2
make: *** [internal-all] Error 2

有什么想法吗?

谢谢。

【问题讨论】:

    标签: ios cydia theos


    【解决方案1】:

    您的标头版本可能搞砸了,因为它们是私有框架标头,而不是官方 Apple 标头。

    两种可能的解决方案:

    1. 从更好的来源重新下载标头。经常推荐rpetrich's versions

    2. 如果这不起作用,请手动编辑标题以解决问题。找到包含PSController 协议的头文件(可能是PSController.h),检查specifier 应该是什么类型,然后在PSViewController.h 中进行更改。我相信我第一次处理 Preference Bundles 时必须做这样的事情。

    【讨论】:

    • 谢谢。我尝试了解决方案 1,但遇到了更多错误,所以我恢复到以前的文件,并准备尝试解决方案 2。在查看头文件时,我注意到 iOSOpenDev 修改了它们(我前一段时间安装了 iOSOpenDev 进行尝试,我'目前没有使用它)。我决定重新安装 Xcode(包括 iOS SDK),看看是否能解决问题。
    • 问题已解决。我重新安装了 Xcode,然后将 rpetrich 的头文件下载到 $THEOS/include 并且还必须 cp /System/Library/Frameworks/IOSurface.framework/Headers/IOSurfaceAPI.h IOSurface/。然后我收到以下错误:/Volumes/Data/Users/derek/iOSProjects/calleridname/theos/include/IOSurface/IOSurfaceAPI.h:251:错误:'xpc_object_t'没有命名类型/Volumes/Data/Users/derek /iOSProjects/calleridname/theos/include/IOSurface/IOSurfaceAPI.h:255: error: 'xpc_object_t' is not declared in this scope 我只是将这些行注释掉并且编译成功。
    猜你喜欢
    • 2014-02-09
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多