Android、Proguard“未知选项”和“在参数 9 中
每次尝试从 Eclipse 导出应用程序时,我都会收到以下错误。
Proguard returned with error code 1. See console
proguard.ParseException: Unknown option 'and' in argument number 9
at proguard.ConfigurationParser.parse(ConfigurationParser.java:170)
at proguard.ProGuard.main(ProGuard.java:491)
我正在使用 Eclipse 生成的默认 proguard.cfg 文件。我的 android sdk 位于 C:\Android\SDK(此处)
我的 default.properties 文件是这样的:
target=android-7
proguard.config=proguard.cfg
我也做了清理和构建。 我还确保 Eclipse 和我的 SDK 工具是最新的。
I'm getting the following error every time I try to export my application from Eclipse.
Proguard returned with error code 1. See console
proguard.ParseException: Unknown option 'and' in argument number 9
at proguard.ConfigurationParser.parse(ConfigurationParser.java:170)
at proguard.ProGuard.main(ProGuard.java:491)
I'm using the defualt proguard.cfg file that Eclipse generated. My android sdk is in C:\Android\SDK(here)
My default.properties file is like this:
target=android-7
proguard.config=proguard.cfg
I have also done a clean and build.
I also made sure Eclipse and my SDK tools were up to date.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
“路径名中的空格”问题在这里有详细记录 - 请注意,您可以使用连接点/链接来解决此问题,而无需移动或重命名文件...
Dalvik 错误通常只是 Eclipse “暂时” - 一个“干净的项目” '并且重建通常可以解决它。
The 'spaces in the pathnames' problem is well documented here - note that you can use Junctions/Links to get around this without moving or renaming files...
The Dalvik error is usually just Eclipse 'having a moment' - a 'Clean Project' and Rebuild usually cures it.
因此,在我的项目名称工作区中,我使用
C:\workspace\Name Android Name
作为名称,因此我将其更改为C:\workspace\NameName
,然后我将我的sdk更改为C:\sdk
,然后导出到C:\NameAndroidName.apk
,并且出现无法转换为dalvik格式的错误。然后我去了 问题解决了dalvik格式错误,并且导出成功。
So, in my workspace for the name of the project I had
C:\workspace\Name Android Name
for the name, so I changed that toC:\workspace\NameName
, then I changed my sdk toC:\sdk
, then I exported toC:\NameAndroidName.apk
, and I got the failure to convert to dalvik format error.And then I went to this question and that solved the dalvik format error, and it exported successfully.