Migrate build system from Ant to Maven
Background
The project currently uses Apache Ant (build.xml) for compilation and packaging. Moving to Maven will enable:
- Automatic dependency resolution from Maven Central (replacing the checked-in JARs in
lib/)
- Standard lifecycle management (
mvn clean package, mvn install, etc.)
- IDE integration (IntelliJ, Eclipse, VS Code) via standard
pom.xml
- Reproducible builds without vendored binaries
- Easy dependency-version upgrades
Ant target → Maven lifecycle mapping
| Ant target |
Maven equivalent |
build (default) |
mvn package |
buildFiles (javac, debug) |
mvn compile via maven-compiler-plugin |
buildReleaseFiles (javac, optimised) |
Maven profile release with <optimize> flag (deprecated in javac 9+; omit) |
jar (copy resources + JAR) |
mvn package via maven-jar-plugin + maven-resources-plugin |
createBuildFolder / removeBuildFolder |
mvn clean via maven-clean-plugin |
run |
mvn exec:java via exec-maven-plugin |
zip |
mvn package -P zip via maven-assembly-plugin |
exe (launch4j Windows exe) |
launch4j-maven-plugin |
createInstaller / runInstallJammer |
No direct Maven equivalent; InstallJammer is abandoned — replace with izpack-maven-plugin or distribute the ZIP only |
uploadToGoogleDownloads |
Obsolete (Google Code shut down) — remove |
Dependency analysis
Available on Maven Central
All coordinates below can be used directly in <dependencies>:
lib/ JAR |
groupId |
artifactId |
version |
Notes |
xercesImpl.jar |
xerces |
xercesImpl |
2.12.2 |
Upgrade; bundled ver has Spec-Version 1.2 (Xerces2-J 2.x) |
xml-apis.jar |
xml-apis |
xml-apis |
1.4.01 |
|
jaxp.jar |
built into JDK |
— |
— |
javax.xml.* is in the JDK since Java 1.4; remove |
avalon-framework.jar |
avalon-framework |
avalon-framework |
4.1.5 |
|
jaxen-1.1.1.jar |
jaxen |
jaxen |
1.1.1 |
|
castor.jar |
org.codehaus.castor |
castor |
0.9.4.3 |
Very old; consider castor-xml 1.4.1 |
dom4j.jar |
dom4j |
dom4j |
1.6.1 |
|
jcalendar.jar |
com.toedter |
jcalendar |
1.3.2 |
|
batik-awt-util.jar |
org.apache.xmlgraphics |
batik-awt-util |
1.6 |
Full batik suite at this groupId |
batik-bridge.jar |
org.apache.xmlgraphics |
batik-bridge |
1.6 |
|
batik-css.jar |
org.apache.xmlgraphics |
batik-css |
1.6 |
|
batik-dom.jar |
org.apache.xmlgraphics |
batik-dom |
1.6 |
|
batik-ext.jar |
org.apache.xmlgraphics |
batik-ext |
1.6 |
|
batik-extension.jar |
org.apache.xmlgraphics |
batik-extension |
1.6 |
|
batik-gui-util.jar |
org.apache.xmlgraphics |
batik-gui-util |
1.6 |
|
batik-gvt.jar |
org.apache.xmlgraphics |
batik-gvt |
1.6 |
|
batik-parser.jar |
org.apache.xmlgraphics |
batik-parser |
1.6 |
|
batik-rasterizer.jar |
org.apache.xmlgraphics |
batik-rasterizer |
1.6 |
|
batik-script.jar |
org.apache.xmlgraphics |
batik-script |
1.6 |
|
batik-squiggle.jar |
org.apache.xmlgraphics |
batik-squiggle |
1.6 |
|
batik-svg-dom.jar |
org.apache.xmlgraphics |
batik-svg-dom |
1.6 |
|
batik-svggen.jar |
org.apache.xmlgraphics |
batik-svggen |
1.6 |
|
batik-swing.jar |
org.apache.xmlgraphics |
batik-swing |
1.6 |
|
batik-transcoder.jar |
org.apache.xmlgraphics |
batik-transcoder |
1.6 |
Also covers pdf-transcoder.jar |
batik-util.jar |
org.apache.xmlgraphics |
batik-util |
1.6 |
|
batik-xml.jar |
org.apache.xmlgraphics |
batik-xml |
1.6 |
|
batik.jar |
org.apache.xmlgraphics |
batik-all |
1.6 |
Aggregate; may replace individual batik-* |
serializer.jar |
xalan |
serializer |
2.7.2 |
|
fop.jar |
fop |
fop |
0.20.5 |
|
jing.jar |
com.thaiopensource |
jing |
20091111 |
|
trang.jar |
com.thaiopensource |
trang |
20091111 |
|
saxon9he.jar |
net.sf.saxon |
Saxon-HE |
9.9.1-8 |
Exact bundled ver unknown; 9.x series |
bsf.jar |
bsf |
bsf |
2.4.0 |
|
resolver.jar |
xml-resolver |
xml-resolver |
1.2 |
|
xalan.jar |
xalan |
xalan |
2.7.2 |
|
xsltc.jar |
xalan |
xalan |
2.7.2 |
Bundled inside xalan; no separate artifact needed |
saxon.jar |
net.sourceforge.saxon |
saxon |
6.5.5 |
Very old XSLT 1.0 processor |
mail.jar |
javax.mail |
mail |
1.4.7 |
Or com.sun.mail:javax.mail:1.6.2 |
activation.jar |
javax.activation |
activation |
1.1.1 |
|
js.jar |
rhino |
js |
1.7R2 |
Or org.mozilla:rhino:1.7.14 |
saaj-api.jar |
javax.xml.soap |
javax.xml.soap-api |
1.3.5 |
|
saaj-impl.jar |
com.sun.xml.messaging.saaj |
saaj-impl |
1.3.28 |
|
xmlsec.jar |
xml-security |
xmlsec |
1.1.0 |
Or org.apache.santuario:xmlsec:3.0.3 |
wsdl4j.jar |
wsdl4j |
wsdl4j |
1.6.3 |
|
commons-logging.jar |
commons-logging |
commons-logging |
1.1 |
|
commons.jar |
commons-cli |
commons-cli |
1.0 |
Contains org.apache.commons.cli.* |
commons-net.jar |
commons-net |
commons-net |
1.4.1 |
|
commons-httpclient.jar |
commons-httpclient |
commons-httpclient |
3.0.1 |
|
jakarta-slide-webdav.jar |
slide |
slide-webdavlib |
2.1 |
Project is retired |
nekohtml.jar |
net.sourceforge.nekohtml |
nekohtml |
0.9.5 |
|
poi.jar |
poi |
poi |
2.5.1 |
|
xbean.jar |
org.apache.xmlbeans |
xmlbeans |
2.0.0 |
|
xbean_xpath.jar |
org.apache.xmlbeans |
xmlbeans-xpath |
2.0.0 |
|
looks-1.3rc.jar |
com.jgoodies |
looks |
1.3.1 |
Use looks.jar (2.1.3) instead |
looks.jar |
com.jgoodies |
looks |
2.1.3 |
|
l2fprod-common-directorychooser.jar |
com.l2fprod |
l2fprod-common-directorychooser |
7.3 |
|
l2fprod-common-totd.jar |
com.l2fprod |
l2fprod-common-totd |
7.3 |
|
rome-0.9.jar |
rome |
rome |
0.9 |
|
rome-fetcher-0.9.jar |
rome |
rome-fetcher |
0.9 |
|
jdom.jar |
jdom |
jdom |
1.0 |
|
isorelax.jar |
isorelax |
isorelax |
20030108 |
|
soap.jar |
soap |
soap |
2.3.1 |
Apache SOAP |
jh.jar |
javax.help |
javahelp |
2.0.05 |
|
kunststoff.jar |
com.incors.plaf |
kunststoff |
2.0.2 |
|
Not on Maven Central — requires manual handling
lib/ JAR |
Package |
Recommendation |
bounce.jar |
org.bounce.* |
Not published to Maven Central. Keep as system scope or install to local repo. See https://bounce.sourceforge.net/ |
MDateSelector.jar |
mseries.ui.* |
Not published. Keep as system scope or install to local repo |
AppleJavaExtensions.jar |
com.apple.* |
Apple stub library for non-Mac compiles. Available as com.apple:AppleJavaExtensions:1.4 on some mirrors; otherwise use system scope. Only needed on non-macOS builds |
jdic.jar |
org.jdesktop.jdic.* |
JDIC project is abandoned. Keep as system scope or remove if functionality unused |
jisp.jar |
com.coyotegulch.jisp.* |
Not published. Keep as system scope |
JbcGrid.jar |
— |
Not present in lib/ — referenced in build.xml but missing. Remove from dependency list |
JbcBeansEvaluation.jar |
— |
Not present in lib/ — referenced in build.xml but missing. Remove from dependency list |
Implementation tasks
-
Create pom.xml with:
- Java 8 source/target (or higher — verify compatibility)
- All Maven Central dependencies above
system-scope entries for the 5 JARs not on Maven Central
maven-compiler-plugin for buildFiles / buildReleaseFiles
maven-jar-plugin with the Manifest.mf main class and Class-Path
maven-resources-plugin to copy icon/resource directories (currently done in the jar Ant target)
maven-assembly-plugin for the zip target (binary distribution)
launch4j-maven-plugin for the exe target (Windows executable)
exec-maven-plugin for the run target
- Remove
uploadToGoogleDownloads target (Google Code is shut down)
- Remove
createInstaller / runInstallJammer targets (InstallJammer is abandoned)
-
Install non-Central JARs to the project's local file-based Maven repository (mvn install:install-file) or use system scope with path relative to ${project.basedir}/lib/.
-
Verify compile with mvn compile
-
Verify package with mvn package — should produce xngr-editor.jar
-
Verify assembly — test maven-assembly-plugin produces the ZIP distribution
-
Remove lib/ from VCS once all resolvable dependencies are declared in pom.xml (or add the 5 non-Central JARs to a lib/ sub-repo and keep only those)
Notes
- The Batik 1.6 JARs bundled in
lib/ had corrupted MANIFEST.MF Class-Path entries (Windows-style \ continuations) that break Java 9+. The Maven Central artifacts for Batik 1.6 do not have this bug.
looks-1.3rc.jar and looks.jar are both present; only looks.jar (2.1.3) should be kept.
jaxp.jar (version 1.1) is entirely superseded by the JDK and can be dropped.
- Two JARs (
JbcGrid.jar, JbcBeansEvaluation.jar) are referenced in build.xml but are not present in lib/ — the build still succeeds, so these references should simply be removed from the pom.xml.
- Consider upgrading old dependencies (Batik 1.6 → 1.17, FOP 0.20.5 → 2.9, POI 2.5 → 5.x, etc.) in a follow-up PR once the Maven migration is stable.
Migrate build system from Ant to Maven
Background
The project currently uses Apache Ant (
build.xml) for compilation and packaging. Moving to Maven will enable:lib/)mvn clean package,mvn install, etc.)pom.xmlAnt target → Maven lifecycle mapping
build(default)mvn packagebuildFiles(javac, debug)mvn compileviamaven-compiler-pluginbuildReleaseFiles(javac, optimised)releasewith<optimize>flag (deprecated in javac 9+; omit)jar(copy resources + JAR)mvn packageviamaven-jar-plugin+maven-resources-plugincreateBuildFolder/removeBuildFoldermvn cleanviamaven-clean-pluginrunmvn exec:javaviaexec-maven-pluginzipmvn package -P zipviamaven-assembly-pluginexe(launch4j Windows exe)launch4j-maven-plugincreateInstaller/runInstallJammerizpack-maven-pluginor distribute the ZIP onlyuploadToGoogleDownloadsDependency analysis
Available on Maven Central
All coordinates below can be used directly in
<dependencies>:lib/JARxercesImpl.jarxercesxercesImpl2.12.2Spec-Version 1.2(Xerces2-J 2.x)xml-apis.jarxml-apisxml-apis1.4.01jaxp.jarjavax.xml.*is in the JDK since Java 1.4; removeavalon-framework.jaravalon-frameworkavalon-framework4.1.5jaxen-1.1.1.jarjaxenjaxen1.1.1castor.jarorg.codehaus.castorcastor0.9.4.3castor-xml1.4.1dom4j.jardom4jdom4j1.6.1jcalendar.jarcom.toedterjcalendar1.3.2batik-awt-util.jarorg.apache.xmlgraphicsbatik-awt-util1.6batik-bridge.jarorg.apache.xmlgraphicsbatik-bridge1.6batik-css.jarorg.apache.xmlgraphicsbatik-css1.6batik-dom.jarorg.apache.xmlgraphicsbatik-dom1.6batik-ext.jarorg.apache.xmlgraphicsbatik-ext1.6batik-extension.jarorg.apache.xmlgraphicsbatik-extension1.6batik-gui-util.jarorg.apache.xmlgraphicsbatik-gui-util1.6batik-gvt.jarorg.apache.xmlgraphicsbatik-gvt1.6batik-parser.jarorg.apache.xmlgraphicsbatik-parser1.6batik-rasterizer.jarorg.apache.xmlgraphicsbatik-rasterizer1.6batik-script.jarorg.apache.xmlgraphicsbatik-script1.6batik-squiggle.jarorg.apache.xmlgraphicsbatik-squiggle1.6batik-svg-dom.jarorg.apache.xmlgraphicsbatik-svg-dom1.6batik-svggen.jarorg.apache.xmlgraphicsbatik-svggen1.6batik-swing.jarorg.apache.xmlgraphicsbatik-swing1.6batik-transcoder.jarorg.apache.xmlgraphicsbatik-transcoder1.6pdf-transcoder.jarbatik-util.jarorg.apache.xmlgraphicsbatik-util1.6batik-xml.jarorg.apache.xmlgraphicsbatik-xml1.6batik.jarorg.apache.xmlgraphicsbatik-all1.6serializer.jarxalanserializer2.7.2fop.jarfopfop0.20.5jing.jarcom.thaiopensourcejing20091111trang.jarcom.thaiopensourcetrang20091111saxon9he.jarnet.sf.saxonSaxon-HE9.9.1-8bsf.jarbsfbsf2.4.0resolver.jarxml-resolverxml-resolver1.2xalan.jarxalanxalan2.7.2xsltc.jarxalanxalan2.7.2xalan; no separate artifact neededsaxon.jarnet.sourceforge.saxonsaxon6.5.5mail.jarjavax.mailmail1.4.7com.sun.mail:javax.mail:1.6.2activation.jarjavax.activationactivation1.1.1js.jarrhinojs1.7R2org.mozilla:rhino:1.7.14saaj-api.jarjavax.xml.soapjavax.xml.soap-api1.3.5saaj-impl.jarcom.sun.xml.messaging.saajsaaj-impl1.3.28xmlsec.jarxml-securityxmlsec1.1.0org.apache.santuario:xmlsec:3.0.3wsdl4j.jarwsdl4jwsdl4j1.6.3commons-logging.jarcommons-loggingcommons-logging1.1commons.jarcommons-clicommons-cli1.0org.apache.commons.cli.*commons-net.jarcommons-netcommons-net1.4.1commons-httpclient.jarcommons-httpclientcommons-httpclient3.0.1jakarta-slide-webdav.jarslideslide-webdavlib2.1nekohtml.jarnet.sourceforge.nekohtmlnekohtml0.9.5poi.jarpoipoi2.5.1xbean.jarorg.apache.xmlbeansxmlbeans2.0.0xbean_xpath.jarorg.apache.xmlbeansxmlbeans-xpath2.0.0looks-1.3rc.jarcom.jgoodieslooks1.3.1looks.jar(2.1.3) insteadlooks.jarcom.jgoodieslooks2.1.3l2fprod-common-directorychooser.jarcom.l2fprodl2fprod-common-directorychooser7.3l2fprod-common-totd.jarcom.l2fprodl2fprod-common-totd7.3rome-0.9.jarromerome0.9rome-fetcher-0.9.jarromerome-fetcher0.9jdom.jarjdomjdom1.0isorelax.jarisorelaxisorelax20030108soap.jarsoapsoap2.3.1jh.jarjavax.helpjavahelp2.0.05kunststoff.jarcom.incors.plafkunststoff2.0.2Not on Maven Central — requires manual handling
lib/JARbounce.jarorg.bounce.*systemscope or install to local repo. See https://bounce.sourceforge.net/MDateSelector.jarmseries.ui.*systemscope or install to local repoAppleJavaExtensions.jarcom.apple.*com.apple:AppleJavaExtensions:1.4on some mirrors; otherwise usesystemscope. Only needed on non-macOS buildsjdic.jarorg.jdesktop.jdic.*systemscope or remove if functionality unusedjisp.jarcom.coyotegulch.jisp.*systemscopeJbcGrid.jarlib/— referenced inbuild.xmlbut missing. Remove from dependency listJbcBeansEvaluation.jarlib/— referenced inbuild.xmlbut missing. Remove from dependency listImplementation tasks
Create
pom.xmlwith:system-scope entries for the 5 JARs not on Maven Centralmaven-compiler-pluginforbuildFiles/buildReleaseFilesmaven-jar-pluginwith theManifest.mfmain class and Class-Pathmaven-resources-pluginto copy icon/resource directories (currently done in thejarAnt target)maven-assembly-pluginfor theziptarget (binary distribution)launch4j-maven-pluginfor theexetarget (Windows executable)exec-maven-pluginfor theruntargetuploadToGoogleDownloadstarget (Google Code is shut down)createInstaller/runInstallJammertargets (InstallJammer is abandoned)Install non-Central JARs to the project's local file-based Maven repository (
mvn install:install-file) or usesystemscope with path relative to${project.basedir}/lib/.Verify compile with
mvn compileVerify package with
mvn package— should producexngr-editor.jarVerify assembly — test
maven-assembly-pluginproduces the ZIP distributionRemove
lib/from VCS once all resolvable dependencies are declared inpom.xml(or add the 5 non-Central JARs to alib/sub-repo and keep only those)Notes
lib/had corruptedMANIFEST.MFClass-Pathentries (Windows-style\continuations) that break Java 9+. The Maven Central artifacts for Batik 1.6 do not have this bug.looks-1.3rc.jarandlooks.jarare both present; onlylooks.jar(2.1.3) should be kept.jaxp.jar(version 1.1) is entirely superseded by the JDK and can be dropped.JbcGrid.jar,JbcBeansEvaluation.jar) are referenced inbuild.xmlbut are not present inlib/— the build still succeeds, so these references should simply be removed from thepom.xml.