forked from relaxng/jing-trang
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build-gcj.xml
61 lines (53 loc) · 2.15 KB
/
build-gcj.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
<project name="jing-trang-gcj" default="gcj-dist">
<property name="topbuild.dir" value="${basedir}/build"/>
<property name="build.dir" value="${topbuild.dir}"/>
<target name="all" depends="test, trang-test, validate"/>
<target name="init">
<mkdir dir="${build.dir}"/>
<mkdir dir="${build.dir}/dist"/>
<condition property="linux">
<os family="unix"/>
</condition>
</target>
<target name="gcj" if="linux" depends="init">
<exec executable="${basedir}/gcj/dist" failonerror="true" dir=".">
<arg value="${build.dir}"/>
</exec>
<checksum fileext=".md5">
<fileset dir="${build.dir}/dist/gcj" includes="*.tar.gz"/>
</checksum>
</target>
<target name="gcj-rpm" depends="gcj" if="linux">
<mkdir dir="${build.dir}/gcj-rpm"/>
<apply executable="rpmbuild" failonerror="true" dir=".">
<arg value="-ta"/>
<arg value="-D"/>
<arg value="_jingbuilddir ${build.dir}"/>
<arg value="--rcfile=gcj/rpmrc"/>
<fileset dir="${build.dir}/dist/gcj" includes="*.tar.gz"/>
</apply>
</target>
<target name="gcj-test" depends="gcj" if="linux">
<mkdir dir="${build.dir}/gcj-test"/>
<untar compression="gzip" dest="${build.dir}/gcj-test">
<fileset dir="${build.dir}/dist/gcj" includes="*.tar.gz"/>
</untar>
<mkdir dir="${build.dir}/gcj-test/jingbuild"/>
<apply dir="${build.dir}/gcj-test/jingbuild" executable="/bin/sh" relative="false" failonerror="true">
<fileset dir="${build.dir}/gcj-test" includes="jing-*/configure"/>
</apply>
<exec executable="make" failonerror="true" dir="${build.dir}/gcj-test/jingbuild"/>
<exec executable="make" failonerror="true" dir="${build.dir}/gcj-test/jingbuild">
<arg value="check"/>
</exec>
<mkdir dir="${build.dir}/gcj-test/trangbuild"/>
<apply dir="${build.dir}/gcj-test/trangbuild" executable="/bin/sh" relative="false" failonerror="true">
<fileset dir="${build.dir}/gcj-test" includes="trang-*/configure"/>
</apply>
<exec executable="make" failonerror="true" dir="${build.dir}/gcj-test/trangbuild"/>
<exec executable="make" failonerror="true" dir="${build.dir}/gcj-test/trangbuild">
<arg value="check"/>
</exec>
</target>
<target name="gcj-dist" depends="gcj-test,gcj-rpm"/>
</project>