-
Notifications
You must be signed in to change notification settings - Fork 2
/
build.xml
606 lines (517 loc) · 22.9 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
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
<?xml version="1.0" encoding="UTF-8"?>
<project name="j" default="build" basedir=".">
<description>Armed Bear J Editor</description>
<target name="j" depends="jar"/>
<property environment="env"/>
<property file="build.properties"/>
<property name="j.version" value="1.0.0"/>
<property name="abcl.version" value="1.8.0"/>
<property name="build.dir" value="${basedir}/build"/>
<property name="build.classes.dir" value="${build.dir}/classes"/>
<property name="build.test.dir" value="${build.dir}/test"/>
<property name="build.lib.dir" value="${build.dir}/lib"/>
<property name="build.bin.dir" value="${build.dir}/bin"/>
<property name="j.jar.path" value="${build.dir}/j.jar"/>
<property name="src.dir" value="${basedir}/src"/>
<property name="test.dir" value="${basedir}/test/src"/>
<property name="tools.dir" value="${basedir}/tools"/>
<property name="dist.dir" value="${basedir}/dist"/>
<property name="deps.dir" value="${basedir}/deps"/>
<property name="abcl.jar.path" value="${basedir}/deps/abcl.jar"/>
<property name="junit.jar.path" value="${basedir}/deps/junit-4.8.2.jar"/>
<condition property="jdk" value="${env.JAVA_HOME}" else="${java.home}">
<isset property="env.JAVA_HOME"/>
</condition>
<property name="javac" value="${jdk}/bin/javac"/>
<property name="tools.jar.path" value="${jdk}/lib/tools.jar"/>
<property name="swingexplorer.dir" value="${deps.dir}/swingexplorer"/>
<property name="javassist.jar.path" value="${swingexplorer.dir}/javassist-3.12.1.GA.jar"/>
<property name="swing-layout.jar.path" value="${swingexplorer.dir}/swing-layout-1.0.3.jar"/>
<property name="swingexplorer-agent.jar.path"
value="${swingexplorer.dir}/swingexplorer-agent-1.7.0.jar"/>
<property name="swingexplorer-core.jar.path"
value="${swingexplorer.dir}/swingexplorer-core-1.7.0.jar"/>
<target name="usage" depends="help" />
<target name="help" depends="install.properties">
<echo>Main Targets:
build -- build J to ${build.classes.dir}
jar -- create packaged ${j.jar.path}
install -- create installation in ${j.install.root}
dist -- create binary and source distributions in ${dist.dir}
clean -- remove J intermediate files
test -- build and run unit tests</echo>
</target>
<property name="j.version.path"
value="${build.classes.dir}/org/armedbear/j/version"/>
<property name="j.build.path"
value="${build.classes.dir}/org/armedbear/j/build"/>
<path id="j.build.classpath">
<pathelement path="${build.classes.dir}"/>
<pathelement path="${abcl.jar.path}"/>
<pathelement path="${tools.jar.path}"/>
</path>
<path id="j.run.classpath">
<path refid="j.build.classpath" />
<pathelement location="${src.dir}"/>
<pathelement path="${extensions}"/>
<pathelement path="${tools.jar.path}"/>
</path>
<path id="test.build.classpath">
<path refid="j.build.classpath"/>
<pathelement path="${junit.jar.path}"/>
</path>
<path id="test.run.classpath">
<path refid="j.run.classpath"/>
<pathelement path="${junit.jar.path}"/>
<pathelement path="${build.test.dir}" />
</path>
<condition property="windows"><os family="windows"/></condition>
<condition property="unix"><os family="unix"/></condition>
<condition property="mac"><os family="mac"/></condition>
<target name="clean" description="-- remove J build and dist files">
<delete dir="${build.dir}"/>
<delete dir="${dist.dir}"/>
</target>
<target name="clean.deps" description="-- remove dependencies">
<delete dir="${deps.dir}"/>
</target>
<target name="stamp" depends="build,stamp.version">
<tstamp>
<format property="j.buildtime" pattern="EEE MMM dd yyyy HH:mm:ss zzz"/>
</tstamp>
<exec executable="hostname" outputproperty="j.hostname"/>
<echo message="${j.buildtime}${line.separator}" file="${j.build.path}"/>
<echo message="${j.hostname}${line.separator}" file="${j.build.path}" append="yes"/>
<!-- UNDONE: get git version string -->
<!--echo message="${git.revision}${line.separator}" file="${j.build.path}" append="yes"/-->
</target>
<target name="stamp.version">
<echo message="${j.version}${line.separator}" file="${j.version.path}"/>
</target>
<patternset id="j.source">
<include name="**/*.java"/>
<!--
<include name="Main.java"/>
<include name="org/armedbear/j/**/*.java"/>
<!- - Assumed to need the org.armedbear.lisp.awt.* classes as ABCL
itself doesn't seem to need them. - ->
<include name="org/armedbear/lisp/awt/*.class"/>
-->
</patternset>
<patternset id="j.objects">
<include name="Main.class"/>
<include name="org/armedbear/j/**/*.class"/>
<include name="org/armedbear/lisp/j.lisp"/>
<include name="org/armedbear/lisp/emacs.lisp"/>
</patternset>
<patternset id="j.resources.src">
<include name="**/*.keywords"/>
<include name="org/armedbear/j/version"/>
<include name="org/armedbear/j/build"/>
<include name="org/armedbear/j/snapshot"/>
<include name="org/armedbear/j/images/**/*.png"/>
</patternset>
<patternset id="j.resources.top">
<include name="COPYING"/>
<include name="doc/*.html"/>
<include name="doc/*.css"/>
<include name="themes/*"/>
<include name="examples/*"/>
</patternset>
<target name="abcl.jar.check">
<available property="abcl.jar.available" file="${abcl.jar.path}"/>
</target>
<target name="abcl.jar.fetch" depends="abcl.jar.check" unless="abcl.jar.available">
<echo message="Fetching abcl.jar ..."/>
<mkdir dir="${deps.dir}"/>
<!-- remove any old versions lying around -->
<delete>
<fileset dir="${deps.dir}" includes="abcl-bin-*.zip" excludes="abcl-bin-${abcl.version}.zip" />
</delete>
<get src="http://common-lisp.net/project/armedbear/releases/${abcl.version}/abcl-bin-${abcl.version}.zip"
usetimestamp="true"
dest="${deps.dir}/abcl-bin-${abcl.version}.zip" />
<unzip src="${deps.dir}/abcl-bin-${abcl.version}.zip"
dest="${deps.dir}">
<patternset>
<include name="**/abcl.jar" />
</patternset>
<flattenmapper />
</unzip>
<available property="abcl.jar.available" file="${abcl.jar.path}"/>
</target>
<target name="abcl.jar" depends="abcl.jar.fetch">
<fail message="failed to find abcl.jar dependency" unless="abcl.jar.available" />
<echo message="using abcl.jar: ${abcl.jar.path}"/>
</target>
<target name="junit.jar.check">
<available property="junit.jar.available" file="${junit.jar.path}"/>
</target>
<target name="junit.jar.fetch" depends="junit.jar.check" unless="junit.jar.available">
<echo message="Fetching junit.jar ..."/>
<mkdir dir="${deps.dir}"/>
<get src="https://repo1.maven.org/maven2/junit/junit/4.8.2/junit-4.8.2.jar"
usetimestamp="true"
dest="${junit.jar.path}" />
<available property="junit.jar.available" file="${junit.jar.path}"/>
</target>
<target name="junit.jar" depends="junit.jar.fetch">
<fail message="failed to find junit.jar dependency" unless="junit.jar.available" />
<echo message="using junit.jar: ${junit.jar.path}"/>
</target>
<target name="dependencies.check" depends="abcl.jar,junit.jar" />
<target name="pre-build" depends="dependencies.check">
<property name="ant.version.min" value="1.10.5" />
<antversion property="ant.version.check" atleast="${ant.version.min}"/>
<fail message="Ant ${ant.version.min} or greater is required." unless="ant.version.check" />
<exec executable="${javac}"
outputproperty="javac.version">
<arg value="-version"/>
</exec>
<fail message="Failed to get javac version" unless="javac.version"/>
<echo>javac.version: ${javac.version}</echo>
<condition property="j.javac.version">
<or>
<matches string="${javac.version}" pattern="16\."/>
<matches string="${javac.version}" pattern="17\."/>
</or>
</condition>
<mkdir dir="${build.dir}"/>
</target>
<target name="javac.warning"
depends="pre-build"
unless="j.javac.version">
<echo>WARNING: javac version ${javac.version} not recommended.</echo>
</target>
<target name="build"
depends="pre-build,javac.warning,jpty"
description="-- build J source">
<mkdir dir="${build.classes.dir}"/>
<javac destdir="${build.classes.dir}"
debug="true"
release="16"
fork="true"
executable="${javac}"
includeantruntime="false"
classpathref="j.build.classpath">
<src path="${src.dir}"/>
<patternset refid="j.source"/>
</javac>
</target>
<target name="jar" depends="build,stamp"
description="-- create packaged j.jar">
<mkdir dir="${build.lib.dir}"/>
<copy file="${abcl.jar.path}" tofile="${build.lib.dir}/abcl.jar"/>
<copy todir="${build.classes.dir}">
<fileset dir="${basedir}/src">
<patternset refid="j.objects"/>
<patternset refid="j.resources.src"/>
</fileset>
</copy>
<jar destfile="${j.jar.path}"
compress="true"
basedir="${build.classes.dir}">
<!--
<patternset refid="j.objects"/>
<patternset refid="j.resources.src"/>
-->
<manifest>
<attribute name="Main-Class" value="Main"/>
<attribute name="Class-Path" value="lib/abcl.jar"/>
<section name="org/armedbear/j">
<attribute name="Implementation-Title" value="ArmedBear J"/>
<attribute name="Implementation-Version" value="${j.version}"/>
<attribute name="Implementation-Build" value="${j.buildtime}"/>
</section>
</manifest>
</jar>
</target>
<target name="dist" depends="dist.bin, dist.win, dist.mac, dist.src"
description="-- create binary and source distributions">
</target>
<target name="dist.stage" depends="jar">
<property name="j.dist.stage.dir" value="${dist.dir}/j-${j.version}"/>
<delete dir="${j.dist.stage.dir}"/>
<mkdir dir="${j.dist.stage.dir}"/>
<copy todir="${j.dist.stage.dir}">
<fileset file="${j.jar.path}"/>
<fileset dir="${basedir}">
<patternset refid="j.resources.top"/>
</fileset>
<fileset dir="${build.dir}" includes="lib/**,bin/**"/>
</copy>
<chmod file="${j.dist.stage.dir}/bin/**" perm="ugo+rx"/>
</target>
<target name="dist.bin" depends="dist.stage">
<property name="j.dist.bin.name" value="j-${j.version}-bin"/>
<delete file="${dist.dir}/${j.dist.bin.name}.tar.gz"/>
<tar tarfile="${dist.dir}/${j.dist.bin.name}.tar.gz"
basedir="${j.dist.stage.dir}"
compression="gzip">
</tar>
<delete file="${dist.dir}/${j.dist.bin.name}.zip"/>
<zip zipfile="${dist.dir}/${j.dist.bin.name}.zip"
basedir="${j.dist.stage.dir}">
</zip>
</target>
<target name="dist.win" depends="dist.stage" if="windows">
<property name="j.dist.win.name" value="j-${j.version}.exe"/>
<delete dir="${dist.dir}/${j.dist.win.name}"/>
<delete dir="${dist.dir}/win-tmp"/>
<mkdir dir="${dist.dir}/win-tmp"/>
<exec executable="jpackage">
<arg value="--verbose"/>
<arg value="--temp"/><arg value="${dist.dir}/win-tmp"/>
<arg value="--name"/><arg value="J"/>
<arg value="--input"/><arg value="${j.dist.stage.dir}"/>
<arg value="--main-jar"/><arg value="j.jar"/>
<arg value="--dest"/><arg value="${dist.dir}"/>
<arg value="--type"/><arg value="exe"/>
<arg value="--app-version"/><arg value="${j.version}"/>
<arg value="--description"/><arg value="ArmedBear J Editor"/>
<arg value="--icon"/><arg value="src/org/armedbear/j/images/icons/j.icns"/>
<arg value="--java-options"/><arg value="-Xms512m"/>
<arg value="--java-options"/><arg value="-Xmx2050m"/>
<!-- TODO: splash image -->
</exec>
</target>
<target name="dist.mac" depends="dist.stage" if="mac">
<property name="j.dist.mac.name" value="J-${j.version}.dmg"/>
<delete dir="${dist.dir}/${j.dist.mac.name}"/>
<delete dir="${dist.dir}/mac-tmp"/>
<mkdir dir="${dist.dir}/mac-tmp"/>
<exec executable="jpackage">
<arg value="--verbose"/>
<arg value="--temp"/><arg value="${dist.dir}/mac-tmp"/>
<arg value="--name"/><arg value="J"/>
<arg value="--input"/><arg value="${j.dist.stage.dir}"/>
<arg value="--main-jar"/><arg value="j.jar"/>
<arg value="--dest"/><arg value="${dist.dir}"/>
<arg value="--type"/><arg value="dmg"/>
<arg value="--app-version"/><arg value="${j.version}"/>
<arg value="--description"/><arg value="ArmedBear J Editor"/>
<arg value="--icon"/><arg value="src/org/armedbear/j/images/icons/j.icns"/>
<arg value="--java-options"/><arg value="-Xms512m"/>
<arg value="--java-options"/><arg value="-Xmx2049m"/>
<arg value="--mac-package-name"/><arg value="J"/>
<!-- TODO: splash image -->
<!-- TODO: sign the package -->
</exec>
</target>
<target name="dist.src" depends="git.check" if="git.available">
<property name="j.dist.src.name" value="j-${j.version}-src"/>
<property name="j.dist.src.dir" value="${dist.dir}/${j.dist.src.name}"/>
<exec executable="git">
<arg value="archive"/>
<arg value="--output=${dist.dir}/${j.dist.src.name}.zip"/>
<arg value="--prefix=${j.dist.src.name}/"/>
<arg value="HEAD"/>
</exec>
<exec executable="git">
<arg value="archive"/>
<arg value="--output=${dist.dir}/${j.dist.src.name}.tar.gz"/>
<arg value="--prefix=${j.dist.src.name}/"/>
<arg value="HEAD"/>
</exec>
</target>
<target name="run">
<java fork="true" spawn="true" classname="Main">
<jvmarg value="-Xdebug"/>
<jvmarg value="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"/>
<!-- put jpty on the PATH -->
<env key="PATH" path="${build.bin.dir}:${env.PATH}"/>
<classpath refid="j.run.classpath" />
<arg value="--debug"/>
<arg value="--force-new-instance"/>
<arg value="--no-session"/>
<arg value="--no-server"/>
<arg value="--no-restore"/>
</java>
</target>
<target name="swingexplorer.check">
<condition property="swingexplorer.available">
<and>
<available file="${javassist.jar.path}" type="file"/>
<available file="${swing-layout.jar.path}" type="file"/>
<available file="${swingexplorer-agent.jar.path}" type="file"/>
<available file="${swingexplorer-core.jar.path}" type="file"/>
</and>
</condition>
</target>
<!-- really ought to be using the Ant maven tasks... -->
<target name="swingexplorer.fetch" depends="swingexplorer.check" unless="swingexplorer.available">
<echo message="Fetching swingexplorer ..."/>
<!-- remove any old versions lying around -->
<delete dir="${swingexplorer.dir}"/>
<mkdir dir="${swingexplorer.dir}"/>
<get src="https://repo1.maven.org/maven2/javassist/javassist/3.12.1.GA/javassist-3.12.1.GA.jar"
usetimestamp="true"
dest="${javassist.jar.path}" />
<get src="https://repo1.maven.org/maven2/org/swinglabs/swing-layout/1.0.3/swing-layout-1.0.3.jar"
usetimestamp="true"
dest="${swing-layout.jar.path}" />
<get src="https://repo1.maven.org/maven2/org/swingexplorer/swingexplorer-agent/1.7.0/swingexplorer-agent-1.7.0.jar"
usetimestamp="true"
dest="${swingexplorer-agent.jar.path}" />
<get src="https://repo1.maven.org/maven2/org/swingexplorer/swingexplorer-core/1.7.0/swingexplorer-core-1.7.0.jar"
usetimestamp="true"
dest="${swingexplorer-core.jar.path}" />
<condition property="swingexplorer.available">
<and>
<available file="${javassist.jar.path}" type="file"/>
<available file="${swing-layout.jar.path}" type="file"/>
<available file="${swingexplorer-agent.jar.path}" type="file"/>
<available file="${swingexplorer-core.jar.path}" type="file"/>
</and>
</condition>
</target>
<target name="swingexplorer" depends="swingexplorer.fetch">
<fail message="failed to find swingexplorer dependency" unless="swingexplorer.available" />
<echo message="using swingexplorer: ${swingexplorer-core.jar.path}"/>
</target>
<target name="run-swingexplorer" depends="swingexplorer">
<java fork="true" spawn="true" classname="org.swingexplorer.Launcher">
<jvmarg value="-Xdebug"/>
<jvmarg value="-Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005"/>
<!-- put jpty on the PATH -->
<env key="PATH" path="${build.bin.dir}:${env.PATH}"/>
<classpath>
<pathelement location="${swingexplorer-core.jar.path}" />
<pathelement location="${abcl.jar.path}"/>
<pathelement location="${build.classes.dir}"/>
<pathelement location="${src.dir}"/>
<pathelement path="${extensions}"/>
<pathelement path="${jdk}/lib/tools.jar"/>
</classpath>
<jvmarg value="-javaagent:${swingexplorer-agent.jar.path}" />
<jvmarg value="-Xbootclasspath/p:${javassist.jar.path}:${swingexplorer-agent.jar.path}" />
<arg value="Main"/>
<arg value="--debug"/>
<arg value="--force-new-instance"/>
<arg value="--no-session"/>
<arg value="--no-server"/>
<arg value="--no-restore"/>
</java>
</target>
<target name="test.build" depends="pre-build,javac.warning">
<mkdir dir="${build.test.dir}"/>
<javac destdir="${build.test.dir}"
debug="true"
fork="true"
executable="${javac}"
includeantruntime="false"
classpathref="test.build.classpath">
<src path="${test.dir}"/>
</javac>
</target>
<target name="test" depends="build,test.build" description="-- build and run tests">
<mkdir dir="${build.dir}/testresults"/>
<junit fork="yes">
<classpath refid="test.run.classpath" />
<batchtest todir="${build.dir}/testresults">
<fileset dir="${test.dir}">
<include name="**/*.java" />
</fileset>
</batchtest>
<formatter type="plain" />
</junit>
</target>
<!--
<target name="TAGS">
<apply executable="etags" parallel="true" verbose="true">
<fileset dir="${src.dir}">
<patternset refid="abcl.source.java"/>
<patternset refid="abcl.source.lisp"/>
</fileset>
</apply>
</target>
-->
<target name="jpty" depends="jpty.build"/>
<target name="jpty.uptodate" if="unix">
<exec executable="gcc" resultproperty="has.gcc" outputproperty="gcc.version"
failonerror="false" failifexecutionfails="false">
<arg line="--version" />
</exec>
<condition property="jpty.uptodate">
<or>
<not><isset property="has.gcc" /></not>
<uptodate srcfile="${src.dir}/jpty/jpty.c"
targetfile="${build.bin.dir}/jpty"/>
</or>
</condition>
</target>
<target name="jpty.build" depends="jpty.uptodate"
if="unix" unless="jpty.uptodate">
<mkdir dir="${build.bin.dir}"/>
<echo message="Compiling jpty..."/>
<exec executable="gcc" dir="${src.dir}/jpty">
<arg line="-Wall -O2 jpty.c -o ${build.bin.dir}/jpty"/>
</exec>
</target>
<target name="install" depends="jar,install.properties"
description="-- create installation in ${j.install.root}">
<property name="j.install.data.dir" value="${j.install.root}/share"/>
<property name="j.install.bin.dir" value="${j.install.root}/bin"/>
<mkdir dir="${j.install.data.dir}/j"/>
<copy file="${j.jar.path}" todir="${j.install.data.dir}/j"/>
<mkdir dir="${j.install.data.dir}/j/lib"/>
<copy file="${abcl.jar.path}" todir="${j.install.data.dir}/j/lib"/>
<!-- set via '-Djava.options=JAVA_OPTIONS' or in 'build.properties -->
<property name="java.options" value=""/>
<path id="j.install.run.classpath">
<fileset dir="${j.install.data.dir}/j" includes="j.jar"/>
<fileset dir="${j.install.data.dir}/j/lib" includes="*.jar"/>
</path>
<copy file="${j.wrapper.file}.in" toFile="${j.install.bin.dir}/${j.wrapper.file}">
<filterset>
<filter token="JAVA"
value="${java.path}"/>
<filter token="JAVA_OPTIONS"
value="${java.options}"/>
<filter token="CLASSPATH"
value="${toString:j.install.run.classpath}"/>
</filterset>
</copy>
<chmod file="${j.install.bin.dir}/j" perm="ugo+rx"/>
<property name="j.install.themes.dir"
value="${j.install.data.dir}/j/themes"/>
<mkdir dir="${j.install.themes.dir}"/>
<copy todir="${j.install.themes.dir}">
<fileset dir="${basedir}/themes"/>
</copy>
<property name="j.install.doc.dir"
value="${j.install.data.dir}/doc/j"/>
<mkdir dir="${j.install.doc.dir}" />
<copy file="${build.bin.dir}/jpty"
todir="${j.install.bin.dir}"
failonerror="false"/>
<chmod file="${j.install.bin.dir}/jpty" perm="ugo+rx"/>
<copy todir="${j.install.data.dir}/doc/j">
<fileset dir="${basedir}/doc"/>
</copy>
</target>
<target name="install.properties"
depends="install.unix.properties,install.windows.properties"/>
<target name="install.unix.properties" if="unix">
<property name="java.path" value="${java.home}/bin/java"/>
<property name="j.install.root" value="/usr/local"/>
<property name="j.wrapper.file" value="j"/>
</target>
<target name="install.windows.properties" if="windows">
<property name="java.path" value="${java.home}\\bin\\java"/>
<property name="j.install.root" value="c:/j"/>
<property name="j.wrapper.file" value="j.bat"/>
</target>
<target name="git.check">
<condition property="git.available">
<and>
<available file="${basedir}/../.git" type="dir" />
<available file="git" type="file">
<filepath>
<pathelement path="${env.PATH}"/>
</filepath>
</available>
</and>
</condition>
</target>
</project>