开发者

Problem med space in path in Proguard parameter call

When I am trying to this parameter to Proguard, it throws this exception:

java -Xms128M -Xmx256M -jar "../../../tools/proguard/proguard.jar" @game_specific.pro -libraryjars "C:/Program Files/Java/jdk1.5.0_22/jre/lib/rt.jar" Error: Expecting class path separ开发者_开发知识库ator ';' before 'Files/Java/jdk1.5.0_22/jre/lib/rt.jar in argument number 3

This is due to the space in the file name, I know that much. I have tried various work-arounds with " and ', but the only thing that works is when I use progra~1 in the path. This is not a viable solution for me, since this command should be able to run on a lot of different computer with various paths to Java.

What am I doing wrong ?


For the sake of convenience, ProGuard accepts arbitrarily grouped command-line arguments, using shell quotes, e.g.:

java -jar proguard.jar "-keep public class * { public <methods>; }"

The shell groups the arguments and gobbles the quotes. As a result, file names containing spaces have to be quoted once more, e.g. with different quotes:

java -jar proguard.jar "-injars 'some input.jar'"

This double-quoting problem doesn't exist for options in configuration files.

The issue is mentioned in the ProGuard manual.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜