-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathbuild.eant
More file actions
131 lines (106 loc) · 4.79 KB
/
build.eant
File metadata and controls
131 lines (106 loc) · 4.79 KB
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
<?xml version="1.0"?>
<project name="ecli_build" default="help">
<description>
system: "ECLI parent project file."
library: "ECLI : Eiffel Call Level Interface (ODBC) Library. Project SAFE."
Copyright: "Copyright (c) 2001-2012, Paul G. Crismer and others"
license: "Eiffel Forum License v2 (see forum.txt)"
date: "$Date$"
</description>
<inherit>
<parent location="${GOBO}/misc/eiffel.eant">
<redefine target="init"/>
<redefine target="prepare_compile"/>
<redefine target="help"/>
<redefine target="install"/>
<redefine target="clean"/>
<redefine target="clobber"/>
</parent>
</inherit>
<!-- Implementation -->
<target name="init">
<precursor/>
<geant target="check_ecli_variables"/>
</target>
<target name="check_ecli_variables">
<echo message="ERROR: GOBO_EIFFEL must be set." unless="${GOBO_EIFFEL}"/>
<echo message="WARNING: ECLI variable not set" unless="${ECLI}"/>
<echo message="WARNING: GOBO_CC variable not set. Must be msc|bcc|gcc|lcc" unless="${GOBO_CC}"/>
<echo message="WARNING: ECLI_C_BCC_DIR variable not set" if="${GOBO_CC}=bcc" unless="${ECLI_C_BCCDIR}"/>
<echo message="WARNING: SAFE_KERNEL variable not set" unless="${SAFE_KERNEL}"/>
<echo message="WARNING: SMARTEIFFELDIR variable not set" unless="${SMARTEIFFELDIR}" if="${GOBO_EIFFEL}=se"/>
</target>
<target unless="${GOBO_OS}=windows" name="prepare_compile" depend="init">
<description>
Prepare compilation : check for C libraries, and compile them if necessary
</description>
<set name="eiffel" value="${GOBO_EIFFEL}"/>
<!-- Check for C libraries -->
<!-- Compile them if necessary -->
<exec executable="make" dir="${ECLI}/src/spec/${eiffel}/${GOBO_OS}"/>
<exec executable="make" dir="${SAFE_KERNEL}/external/src/spec/${eiffel}/${GOBO_OS}"/>
</target>
<target if="${GOBO_OS}=windows" name="prepare_compile_windows" depend="init">
<description>
Prepare compilation : check for C libraries, and compile them if necessary
</description>
<set name="eiffel" value="${GOBO_EIFFEL}"/>
<!-- Check for C libraries -->
<!-- safe kernel lib Compile them if necessary -->
<exec executable="nmake -f makefile.mak" dir="${SAFE_KERNEL}/external/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=msc"/>
<exec executable="make -f makefile.bcc" dir="${SAFE_KERNEL}/external/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=bcc"/>
<exec executable="make -f makefile.lcc SMARTEIFFELDIR=${SMARTEIFFELDIR}" dir="${SAFE_KERNEL}/external/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=lcc"/>
<exec executable="make -f Makefile.gcc" dir="${SAFE_KERNEL}/external/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=gcc"/>
<!-- Compile them if necessary -->
<exec executable="nmake -f makefile.mak" dir="${ECLI}/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=msc"/>
<exec executable="make -f makefile.bcc" dir="${ECLI}/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=bcc"/>
<exec executable="make -f makefile.lcc SMARTEIFFELDIR=${SMARTEIFFELDIR}" dir="${ECLI}/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=lcc"/>
<exec executable="make -f Makefile.gcc" dir="${ECLI}/src/spec/${eiffel}/${GOBO_OS}" if="${GOBO_CC}=gcc"/>
</target>
<target name="install" depend="compile_libs, compile_tools">
<description>
Call 'geant' with the same target ${target}
in all subdirectories.
</description>
</target>
<target name="compile_libs" depend="prepare_compile, prepare_compile_windows">
</target>
<target name="compile_tools">
<description>
Compile tools
</description>
<geant file="build.eant" target="compile" dir="${ECLI}/tools"/>
</target>
<target name="help">
<echo message=" geant install"/>
<echo message=" geant compile_libs"/>
<echo message=" geant compile_tools"/>
<echo message=" geant clean"/>
<echo message=" geant clobber"/>
</target>
<target name="help2">
<echo message=" geant compile_libs"/>
<echo message=" geant install"/>
<echo message=" geant compile"/>
<echo message=" geant compile_ise"/>
<echo message=" geant compile_ge"/>
<echo message=" geant compile_se"/>
<echo message=" geant compile_debug_ise"/>
<echo message=" geant compile_debug_ge"/>
<echo message=" geant compile_debug_se"/>
<echo message=" geant clean"/>
<echo message=" geant clobber"/>
</target>
<target name="clean">
<set name="target" value="clean"/>
<geant target="do_all"/>
</target>
<target name="clobber">
<set name="target" value="clobber"/>
<geant target="do_all"/>
</target>
<!-- Implementation -->
<target name="do_all">
<geant file="build.eant" target="${target}" dir="${ECLI}/tools"/>
</target>
</project>