This repository has been archived by the owner on Feb 13, 2018. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 8
/
build.xml
executable file
·58 lines (49 loc) · 2.64 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
<?xml version="1.0" encoding="UTF-8"?>
<!-- ============================================ -->
<!-- XE Board build file -->
<!-- Build a new board distribution by running: -->
<!-- phing -Dversion=1.2 -->
<!-- from the board module folder -->
<!-- Make sure you update conf/info.xml and -->
<!-- create svn tag first. -->
<!-- Tag name should be version number. -->
<!-- ============================================ -->
<project name="xe-board" default="dist">
<property name="version" value="" override="true" />
<property name="config.build_dir" value="./build" override="true" />
<property name="config.build_dir_module_folder" value="./build/xe-board" override="true" />
<property name="config.svn" value="D:\svn\bin\svn.exe" override="true" />
<property name="release.repo" value="http://xe-board.googlecode.com/svn/tags/${version}" override="true" />
<property name="release.name" value="xe-board.${version}" override="true" />
<!-- ============================================ -->
<!-- Target: prepare -->
<!-- ============================================ -->
<target name="prepare">
<echo msg="Removing directory ${config.build_dir}" />
<exec command="rm -rf ${config.build_dir}" />
<echo msg="Making directory ${config.build_dir}" />
<mkdir dir="${config.build_dir}" />
</target>
<!-- ============================================ -->
<!-- Target: build -->
<!-- ============================================ -->
<target name="build" depends="prepare">
<echo msg="Exporting repo files to build directory..." />
<exec command="${config.svn} export ${release.repo} ${config.build_dir_module_folder}" />
<exec command="rm -f ${config.build_dir_module_folder}/build.xml" />
</target>
<!-- ============================================ -->
<!-- (DEFAULT) Target: dist -->
<!-- ============================================ -->
<target name="dist" depends="build">
<echo msg="Creating archive..." />
<tar destfile="${config.build_dir}/${release.name}.tar.gz" compression="gzip">
<fileset dir="${config.build_dir_module_folder}">
<include name="*" />
</fileset>
</tar>
<zip destfile="${config.build_dir}/${release.name}.zip" basedir="${config.build_dir_module_folder}" />
<exec command="rm -rf ${config.build_dir_module_folder}" />
<echo msg="Files copied and compressed in build directory OK!" />
</target>
</project>