【问题标题】:How to programatically install a ipa file in iOS 6如何以编程方式在 iOS 6 中安装 ipa 文件
【发布时间】:2013-02-25 16:06:18
【问题描述】:

我们使用 iOS 私有框架 MobileInstallationInstall,它在 iOS 5 中运行良好,如下所示:

typedef int (*MobileInstallationInstall)(NSString *path, NSDictionary *dict, void *na, NSString *path2_equal_path_maybe_no_use);

int result=pMobileInstallationInstall(ipaPath,[NSDictionary dictionaryWithObject:@"User" forKey:@"ApplicationType"],nil,ipaPath);

但是,在 iOS 6 中,这个方法 (pMobileInstallationInstall) 总是返回 -1。

有人可以帮助我吗?非常感谢...

【问题讨论】:

    标签: ios installation ipa


    【解决方案1】:

    请关注How do I change my iOS applications' entitlements?为您的应用签名,您需要将以下内容添加到xml文件中。

    <key>com.apple.private.mobileinstall.allowedSPI</key>
    <array>
        <string>Install</string>
        <string>Browse</string>
        <string>Uninstall</string>
        <string>Archive</string>
        <string>RemoveArchive</string>
    </array>
    

    【讨论】:

    • @mihirmehta 你好,这个解决方案是否有效,因为它总是返回-1。有什么建议吗?
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2020-06-12
    • 1970-01-01
    • 1970-01-01
    • 2019-06-06
    • 1970-01-01
    • 2012-09-29
    • 2020-04-19
    相关资源
    最近更新 更多