How to include C/C++ code compile/link in Ant build?

Erik Hatcher

Besides <exec> to Make or other native programs, there is now a very elegant task and set of datatypes surrounding the <cc> task that are designed to allow Ant to call the compilers directly in a cross-platform manner, and handle all the dependency checking necessary. Download the CPPTasks from SourceForge. That archive contains the right JAR.