1 <!-- ant file to make libnxt, runc, nxjflash and jlibnxt -->
3 <project name="libnxt" default="make" basedir=".">
4 <property name="endian" value="_NXT_LITTLE_ENDIAN"/>
5 <!-- cpptasks task & type def
6 <taskdef resource="cpptasks.tasks">
8 <pathelement location="../jtools/3rdparty/lib/cpptasks.jar"/>
11 <typedef resource="cpptasks.types">
13 <pathelement location="../jtools/3rdparty/lib/cpptasks.jar"/>
18 <!-- cleans all compilation artifacts -->
19 <target name="clean" description="cleans all compilation artifacts">
27 <!-- make libnxt and its utilities -->
28 <target name="make" depends="clean,libnxt,nxjflash,jlibnxt" description="makes libnxt and its tools">
32 <target name="libnxt" description="makes libnxt">
33 <cc subsystem="console"
42 <compilerarg value="-Wall"/>
43 <compilerarg value="-std=gnu99"/>
44 <compilerarg value="-g"/>
45 <compilerarg value="-ggdb"/>
46 <compilerarg value="-D${endian}"/>
48 <include name="error.c"/>
49 <include name="firmware.c"/>
50 <include name="flash_routine.c"/> <include name="error.c"/>
51 <include name="flash.c"/>
52 <include name="lowlevel.c"/>
53 <include name="samba.c"/>
56 <pathelement location="."/>
58 <versioninfo refid="libnxt"/>
63 <target name="runc" description="makes runc utility">
64 <cc subsystem="console"
73 <compilerarg value="-Wall"/>
74 <compilerarg value="-std=gnu99"/>
75 <compilerarg value="-g"/>
76 <compilerarg value="-ggdb"/>
77 <compilerarg value="-D_NXT_LITTLE_ENDIAN"/>
79 <include name="main_runc.c"/>
81 <libset dir="." libs="nxt,usb"/>
83 <pathelement location="."/>
85 <versioninfo refid="runc"/>
89 <!-- make nxjflash -->
90 <target name="nxjflash" description="makes nxjflash utility">
91 <cc subsystem="console"
100 <compilerarg value="-Wall"/>
101 <compilerarg value="-std=gnu99"/>
102 <compilerarg value="-g"/>
103 <compilerarg value="-ggdb"/>
104 <compilerarg value="-D_NXT_LITTLE_ENDIAN"/>
106 <include name="main_nxjflash.c"/>
108 <libset dir="." libs="nxt,usb"/>
110 <pathelement location="."/>
112 <versioninfo refid="nxjflash"/>
116 <!-- make jlibnxt -->
117 <target name="jlibnxt" description="makes jlibnxt">
118 <cc subsystem="console"
127 <compilerarg value="-Wall"/>
128 <compilerarg value="-std=gnu99"/>
129 <compilerarg value="-g"/>
130 <compilerarg value="-ggdb"/>
131 <compilerarg value="-D${endian}"/>
133 <include name="main_jlibnxt.c"/>
135 <libset dir="." libs="nxt,usb"/>
137 <pathelement location="."/>
139 <versioninfo refid="libnxt"/>