Difference between revisions of "ANT"
(→Building) |
(Add notes on fix for out of memory error) |
||
(One intermediate revision by one other user not shown) | |||
Line 21: | Line 21: | ||
==Building== | ==Building== | ||
− | # Open a command line, change to where you fetched PCGen from SVN, and test ant: | + | # Open a command line, change to where you fetched PCGen from SVN, and test ant: ''ant -projecthelp'', you should see a large list of targets with descriptions. If all is not well, please refer to the Ant documentation or drop one of the lists a line with your situation. |
# Build pcgen and run the tests (note that test is the default target for our build.xml ant script): ''ant'', you should see lots of output, hopefully a tests successful at the end. You are now ready to use Ant for command line builds, please see [[Building PCGen]] for more details | # Build pcgen and run the tests (note that test is the default target for our build.xml ant script): ''ant'', you should see lots of output, hopefully a tests successful at the end. You are now ready to use Ant for command line builds, please see [[Building PCGen]] for more details | ||
NB You can also use ant integration with your IDE (Eclipse and IDEA both support ant out of the box). | NB You can also use ant integration with your IDE (Eclipse and IDEA both support ant out of the box). | ||
+ | |||
+ | |||
+ | ==Troubleshooting== | ||
+ | If you get out of memory issues, then you need to supply more memory to the JVM running ant. You can do this by setting the ANT_OPTS environment variable to something like | ||
+ | * -DXms=1024M -DXmx=1024M -XX:+UseParallelGC |
Latest revision as of 20:51, 13 November 2008
Introduction
PCGen is traditionally built with Ant. Here is how you can run ant:
Install ANT
- Get ANT from the Apache Ant site. The current version is just fine.
- Unpack it wherever you will.
- See the Ant Installation Guide. It basically means that you should add these two environment variables (the example is for Windows, adjust accordingly for other platforms).
ANT_HOME=wherever you unpacked ant, e.g., C:\ant-1.6.5
Add the following to the end of the PATH variable ;%ANT_HOME%\bin
For windows you can set (or update) these through the UI by
- Right click on my computer
- Select properties
- Click advanced and then Environment variables
- Under the System Variables list, click New
Building
- Open a command line, change to where you fetched PCGen from SVN, and test ant: ant -projecthelp, you should see a large list of targets with descriptions. If all is not well, please refer to the Ant documentation or drop one of the lists a line with your situation.
- Build pcgen and run the tests (note that test is the default target for our build.xml ant script): ant, you should see lots of output, hopefully a tests successful at the end. You are now ready to use Ant for command line builds, please see Building PCGen for more details
NB You can also use ant integration with your IDE (Eclipse and IDEA both support ant out of the box).
Troubleshooting
If you get out of memory issues, then you need to supply more memory to the JVM running ant. You can do this by setting the ANT_OPTS environment variable to something like
- -DXms=1024M -DXmx=1024M -XX:+UseParallelGC