Increasing Heap Size While Building With Ant

February 12, 2008 at 11:54 am (Java)

Things are easy to manage memory while building applications using java.exe.

But while using ant for building big codes, we need to set the memory limit using a parameter ANT_OPTS

just set the above thing in environment variables and give the size as the value in the following fashion to get things going.

-Xmx<size>m

eg. set ANT_OPTS =-Xmx512m

in unix – setenv ANT_OPTS -Xmx768m

Advertisements

1 Comment

  1. Abhihome said,

    This is the solution 99% of the time. But mine was fixed by a re-installation of Java!

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: