Details
-
Type:
Bug
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: JRuby 1.1.5
-
Fix Version/s: JRuby 1.2
-
Component/s: None
-
Labels:None
-
Environment:MacOS 10.5.5 Java 1.5.0_16
-
Patch Submitted:Yes
-
Number of attachments :
Description
Running the ant task api-docs to generate the Javadoc runs out of memory on my MacOS 10.5.5 system running Java 1.5.0_16:
[javadoc] javadoc: error - java.lang.OutOfMemoryError: Please increase memory. [javadoc] For example, on the Sun Classic or HotSpot VMs, add the option -J-Xmx [javadoc] Generating /Users/stephen/dev/ruby/src/jruby.git/docs/api/serialized-form.html... [javadoc] 5 errors [javadoc] 324 warnings [javadoc] such as -J-Xmx32m. BUILD SUCCESSFUL Total time: 8 minutes 18 seconds
Adding attribute: maxmemory="128m" fixes this problem and decreases the time to build the javadoc from over 8 minutes to under 40s:
[javadoc] Building index for all classes...
[javadoc] Generating /Users/stephen/dev/ruby/src/jruby.git/docs/api/stylesheet.css...
[javadoc] 4 errors
[javadoc] 325 warnings
BUILD SUCCESSFUL
Total time: 39 seconds
patch:
diff --git a/build.xml b/build.xml index 36c5177..d7db139 100644 --- a/build.xml +++ b/build.xml @@ -1051,7 +1051,8 @@ <target name="create-apidocs" depends="prepare" description="Creates the Java API docs"> <javadoc destdir="${api.docs.dir}" author="true" version="true" use="true" - windowtitle="JRuby API" source="${javac.version}" useexternalfile="true"> + windowtitle="JRuby API" source="${javac.version}" useexternalfile="true" + maxmemory="128m"> <fileset dir="${src.dir}"> <include name="**/*.java"/> </fileset>
Patch applied in commit 8379. Thanks Stephen.