Java - 将应用程序提交到 Mac 商店时出错(不推荐使用 API) [英] Java - error when submitting app to Mac Store (deprecated API usage)

查看:32
本文介绍了Java - 将应用程序提交到 Mac 商店时出错(不推荐使用 API)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我尝试将 Java 应用程序提交到 mac 商店(当然 JRE 是捆绑的),但得到了著名的无效二进制错误".在来自 iTunes 的电子邮件中,我收到消息Apple 不再接受使用 Quick Time API 的应用程序的提交".这可能意味着捆绑的 JRE 指向 QTKit 框架或 QuickTime 框架.我查了一下,MAC OS X 10.9 不再支持这个 API.

I tried to submit Java app to mac store (of course JRE is bundled), but got famous "Invalid Binary Error". In the email from iTunes I got message that "Apple no longer accepts submissions of apps that use Quick Time APIs". That probably means that the bundled JRE points to QTKit Framework or QuickTime Framework. I checked and this API is no longer supported in MAC OS X 10.9.

我使用 Java 1.7.40.

I use Java 1.7.40.

是否有人知道 Java 在哪里引用这些框架,以及是否可以删除这些二进制文件?我认为这是一个非常新的问题,我希望有解决方案.

Do have somebody idea where do Java reference these frameworks and if it is possible to remove those binaries ? I think this is quite fresh problem and I hope there is solution for that.

谢谢,路博斯

推荐答案

我以预期的速度更快地解决了这个问题.以下是一些详细信息.

I resolved the issue faster as I expected. Here are some details.

在捆绑的 JRE 目录上运行 Unix 命令 otool -L 以查找所有 *dylib 文件.这将列出所有 dylib 文件的所有引用.然后你只需要在结果中搜索字符串QTKit".在 java 1.7.40 的情况下,有 2 个库,引用该框架:

Run Unix command otool -L over directory of bundled JRE to find all *dylib files. This will list all the references of all the dylib files. Then you just need to search in the results the string "QTKit". In the case of java 1.7.40, there are 2 libraries, referencing that Framework:

libgstplugins-lite.dylib,libjfxmedia.dylib

如果您的应用程序不使用它们,那么您很幸运,只需将它们删除即可.

If your application doesn't use them, you're lucky and just remove them.

Unix 命令示例:

otool -L/Library/Java/JavaVirtualMachines/jdk1.7.0_40.jdk/Contents/Home/jre/lib/*dylib

希望这能帮助那些想在 OS X 10.9 中弃用 GTKit.framework 之后将 Java 应用程序提交到 Mac 商店的人.

Hopefully this will help guys, who want to submit Java app to Mac store after GTKit.framework was deprecated in OS X 10.9.

注意:这对 Java 1.7.40 有效,可能对于新的 Java 版本,这已经修复了.

Note: this is valid for Java 1.7.40, it might be that for new java versions, this is already fixed.

问候,

路博斯

这篇关于Java - 将应用程序提交到 Mac 商店时出错(不推荐使用 API)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆