Ant+ivy
This page explains how to compile your code when you use the Apache Ant build tool. We suggest you use ivy, the ant add-on that lets you fetch dependencies from the internet automatically.
Lombok just needs to be on the classpath when you compile your code to do its work, so all you have to ensure, is that lombok is on the classpath in your <javac>
task.
Just ant
Assuming that you've put lombok.jar
in a lib
dir, your javac task would have to look like:
<javac srcdir="src" destdir="build" source="1.8"> <classpath location="lib/lombok.jar" /> </javac>
Ant with Ivy
Lombok is available in Maven Central, so you can tell ivy to fetch lombok like so (assuming you have a configuration named build
:
<dependencies> <dependency org="org.projectlombok" name="lombok" rev="1.18.36" conf="build->master" /> </dependencies>