-
Notifications
You must be signed in to change notification settings - Fork 46
/
build.xml
119 lines (97 loc) · 5.23 KB
/
build.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
<!--
This file is part of JavaSMT,
an API wrapper for a collection of SMT solvers:
https://github.com/sosy-lab/java-smt
SPDX-FileCopyrightText: 2020 Dirk Beyer <https://www.sosy-lab.org>
SPDX-License-Identifier: Apache-2.0
-->
<!-- vim: set tabstop=8 shiftwidth=4 expandtab : -->
<project name="JavaSMT Solver Library" basedir="." default="build">
<!-- Include a file in which all properties can be overridden.
This file won't get checked in and can be used to change properties
locally for one machine if necessary. -->
<property file="build.properties"/>
<property environment="env"/>
<!-- Yices2 is under GPL3 and has to be seperated from Apache2-licensed software. -->
<property name="yices2Sources" value="org/sosy_lab/java_smt/solvers/yices2/**.java"/>
<property name="yices2Classes" value="org/sosy_lab/java_smt/solvers/yices2/**.class"/>
<!-- one configuration per solver -->
<property name="ivy.solver.configurations" value="
runtime-bitwuzla,
runtime-boolector,
runtime-cvc4,
runtime-cvc5,
runtime-mathsat,
runtime-opensmt,
runtime-optimathsat,
runtime-princess,
runtime-smtinterpol,
runtime-yices2,
runtime-z3
"/>
<property name="ivy.configuration.main" value="core"/>
<property name="ivy.configurations" value="build, ${ivy.configuration.main}, ${ivy.solver.configurations}, test, format-source, checkstyle, spotbugs"/>
<property name="package" value="java_smt"/>
<property name="jar.excludes" value="**/*Test.class **/*Test$*.class ${yices2Classes} **/*smt2"/>
<property name="jar.sources.excludes" value="**/*Test.java ${yices2Sources}"/>
<property name="jar.excludesInYices2Jar" value=""/> <!-- only excluded in the Jar for Yices2 bindings -->
<property name="ivy.contrib.present" value="true"/> <!-- always download sources -->
<property name="documentation.javadoc.exclude" value="org/sosy_lab/java_smt/solvers/**/*"/>
<!-- This check crashes current error-prone -->
<property name="errorprone.options" value="-Xep:Finally:OFF -Xep:MissingSummary:OFF -Xep:UnescapedEntity:OFF"/>
<!-- Maven Central metadata -->
<property name="ivy.pom.description" value="Unified acccess layer to SMT solvers"/>
<property name="ivy.pom.url" value="https://github.com/sosy-lab/java-smt"/>
<property name="ivy.pom.name" value="java-smt"/>
<property name="ivy.pom.groupId" value="org.sosy-lab"/>
<property name="ivy.pom.artifactId" value="java-smt"/>
<import file="build/build-version.xml"/>
<import file="build/build-ivy.xml"/>
<import file="build/build-compile.xml"/>
<import file="build/build-documentation.xml"/>
<import file="build/build-jar.xml"/>
<import file="build/build-junit.xml"/>
<import file="build/build-format-source.xml"/>
<import file="build/build-checkstyle.xml"/>
<import file="build/build-spotbugs.xml"/>
<import file="build/build-publish.xml"/>
<import file="build/build-publish-solvers.xml"/>
<import file="build/build-maven-publish.xml"/>
<path id="classpath">
<pathelement location="${class.dir}"/>
<fileset dir="${ivy.lib.dir}" includes="runtime-*/*.jar test/*.jar build/annotations.jar build/auto-value-annotations.jar build/error_prone_annotations.jar"/>
</path>
<!-- Needs to include all annotation processors and error-prone -->
<path id="processorpath">
<fileset dir="${ivy.lib.dir}" includes="build/*.jar runtime/common.jar"/>
</path>
<!-- Main targets -->
<target name="clean" description="Clean">
<property name="bitwuzla.path" value="${user.dir}/lib/native/source/libbitwuzla"/>
<delete includeEmptyDirs="true">
<fileset dir="." includes="${class.dir}/** ${ivy.module}-*.jar ivy-*.xml *.so *.dll *.dylib *.jar"/>
<fileset dir="lib/native/source/libmathsat5j" includes="*.so *.dll *.o"/>
<fileset dir="${bitwuzla.path}" includes="include/"/>
<fileset dir="${bitwuzla.path}" includes="bitwuzla_wrap.o"/>
</delete>
</target>
<target name="build" depends="build-project, collect-options" description="Build"/>
<target name="dist" depends="jar, sources, javadoc-jar" description="Make a distributable release"/>
<target name="tests" depends="unit-tests-coverage" description="Run all tests"/>
<target name="publish" depends="tests, dist, publish-artifacts" description="Publish current version of JavaSMT to Ivy repository" />
<target name="documentation" depends="collect-options, javadoc" description="Build documentation"/>
<target name="all-checks" description="Run all tests and checks">
<!-- We have to use antcall here to run clean twice. -->
<antcall target="clean"/>
<antcall target="build-project-ecj"/>
<antcall target="clean"/>
<antcall target="standard-checks"/>
</target>
<!-- Auxiliary targets -->
<target name="init" depends="determine-version">
<echo message="Building ${ant.project.name} ${version}"/>
<mkdir dir="${class.dir}"/>
</target>
<target name="build-dependencies" depends="init, resolve-dependencies"/>
<target name="standard-checks" depends="tests, spotbugs, checkstyle, javadoc"/>
</project>