如何使用Proguard Maven插件为Proguard分配更多内存? [英] How do I allocate more memory to Proguard with the Proguard Maven Plugin?

查看:132
本文介绍了如何使用Proguard Maven插件为Proguard分配更多内存?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尝试使用Proguard Maven插件时出现OutOfMemoryErrors.我尝试通过将MAVEN_OPTS环境变量设置为-Xmx2g来为Maven分配更多的内存,但这没有任何区别.我认为proguard必须在单独的进程中运行.

I'm getting OutOfMemoryErrors when trying to use the Proguard Maven Plugin. I have tried allocating more memory to Maven by setting the MAVEN_OPTS environment variable to -Xmx2g but this doesn't make any difference. I assume that proguard must run in a separate process.

推荐答案

据我所知,proguard-maven-plugin具有一个单独的配置条目:

As far as I know proguard-maven-plugin has a separate configuration entry for that:

  <plugin>
   <groupId>com.pyx4me</groupId>
   <artifactId>proguard-maven-plugin</artifactId>
   <version>2.0.4</version>
   ...
   <configuration>        
     <maxMemory>576m</maxMemory>
   </configuration>
  </plugin>

您是对的,proguard在分叉的过程中运行.

And you're right, proguard runs in a forked process.

这篇关于如何使用Proguard Maven插件为Proguard分配更多内存?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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