Detailed instructions on how to use Maven to build Soot can be found here.
Migrating to Maven
Migrating Soot’s current Ant build to Maven required us to replace each Ant tasks successively with a corresponding Maven plugin/configuration.
First, we deployed all dependencies Soot requires to build onto our Nexus server https://soot-build.cs.upb.de/nexus/repository/soot-release/, excluding all dependencies that are already deployed in Maven Central.
Consequently, we could delete the
lib folder in the repository and let maven resolve all dependencies.
Second, we had to replace the Ant XSL task with an appropriate configuration of the
xml-maven-plugin to generate all Soot options and singletons properly during a build
Third, we had to generate the code for all test classes and include resource files in the resulting jar. The result of our work can be found here https://github.com/Sable/soot/blob/develop/pom.xml.
Anyway, it is now possible to simply build a project against Soot including the following snippet in the project’s
<dependencies> <dependency> <groupId>ca.mcgill.sable</groupId> <artifactId>soot</artifactId> <version>3.0.0-SNAPSHOT</version> </dependency> </dependencies> <repositories> <repository> <id>soot-snapshot</id> <name>soot snapshots</name> <url>https://soot-build.cs.uni-paderborn.de/nexus/repository/soot-snapshot/</url> </repository> </repositories>
Soot CI - Jenkins & Nexus
Manuel Benz installed and configured the Jenkins and Nexus server for Soot. Luckily, due to my previous experience with MechatronicUML’s build server, I could support him and we could set up the servers really fast.
- Jenkins is available via https://soot-build.cs.upb.de/jenkins/
- Nexus is available via https://soot-build.cs.upb.de/nexus/
He also configured Let’s Encrypt certificates!
Side Note: The let’s encrypt CA certificates are contained in Java versions >= 1.8.151 only. Using a prior Java version Maven cannot validate the certificates and throws an exception.
A nice feature of the Jenkins setup is that all pull-request can be built and tested flawlessly! A simple
ok to test
please retest this
is sufficient to trigger all Jenkins checks for the pull-request.
Thanks @Manuel Benz!