annotate configure.sh @ 249:00767f051056

components/etm: rm modules for ATP and LCC
author Mychaela Falconia <falcon@freecalypso.org>
date Wed, 12 May 2021 03:06:34 +0000
parents ee04ca45053d
children e17bdedfbf2b
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 #!/bin/sh
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 set -e
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 if [ ! -f configure.sh ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 echo "This script needs to be run from the top of the source tree" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 if [ ! -f helpers/makeline ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 echo "Please run make in the helpers directory first" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 # start looking at our invokation line
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19 if [ "$1" = --clean ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 clean_flag=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22 shift
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 else
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24 clean_flag=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 if [ $# -lt 2 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 echo "usage: $0 [--clean] target config [vars]" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33 TARGET="$1"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 CONFIG="$2"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 if [ ! -f "targets/$TARGET.conf" -o ! -f "targets/$TARGET.h" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 echo "Error: target $TARGET not known" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 if [ ! -f "configs/$CONFIG" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 echo "Error: configuration $CONFIG not known" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 # target defaults that can be overridden by $TARGET.conf
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 CHIPSET=10
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 DSP=36
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52 RF=12
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 DISABLE_SLEEP=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 FCHG_STATE=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55 RVTMUX_ON_MODEM=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
57 . "targets/$TARGET.conf"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
58
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
59 # settings derived from the target-defined DSP version
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
60
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
61 case "$DSP" in
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
62 33)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
63 AMR=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
64 L1_DYN_DSP_DWNLD=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
65 L1_VOICE_MEMO_AMR=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
66 MELODY_E2=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
67 SPEECH_RECO=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
68 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
69 34)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
70 AMR=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
71 L1_DYN_DSP_DWNLD=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
72 L1_VOICE_MEMO_AMR=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
73 MELODY_E2=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
74 SPEECH_RECO=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
75 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
76 36)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
77 AMR=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
78 L1_DYN_DSP_DWNLD=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
79 L1_VOICE_MEMO_AMR=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
80 MELODY_E2=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
81 SPEECH_RECO=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
82 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
83 *)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
84 echo "Error: DSP=$DSP setting not understood" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
85 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
86 esac
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
87
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
88 # functional configuration part
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
89
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
90 # these vars MUST be set by the functional config
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
91 GPRS=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
92 MMI=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
93 R2D_STATE=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
94 SRVC=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
95
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
96 # dummy defaults for sans-UI configs
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
97 R2D_EMBEDDED_LCD=7
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
98 UI_CONFIG=bigcolor
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
99
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
100 # apply functional config
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
101
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
102 . "configs/$CONFIG"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
103
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
104 # verify it
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
105
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
106 if [ -z "$GPRS" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
107 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
108 echo "Error: configs/$CONFIG must set GPRS=" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
109 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
110 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
111
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
112 if [ -z "$MMI" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
113 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
114 echo "Error: configs/$CONFIG must set MMI=" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
115 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
116 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
117
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
118 if [ -z "$R2D_STATE" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
119 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
120 echo "Error: configs/$CONFIG must set R2D_STATE=" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
121 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
122 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
123
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
124 if [ -z "$SRVC" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
125 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
126 echo "Error: configs/$CONFIG must set SRVC=" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
127 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
128 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
129
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
130 if [ "$MMI" != 0 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
131 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
132 FCHG_STATE=1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
133 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
134
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
135 # miscellaneous configurable feature settings
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
136
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
137 ALLOW_CSIM_GSM=1
38
e58a5bb12de4 experimental support for GPF memory supervision
Mychaela Falconia <falcon@freecalypso.org>
parents: 34
diff changeset
138 MEMSUPER=0
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
139 OSL=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
140 OSX=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
141 SERIAL_DYNAMIC_SWITCH=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
142 TI_PROFILER=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
143 TRACEMASK_IN_FFS=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
144 TR_BAUD_CONFIG=TR_BAUD_115200
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
145 USE_CACHE=1
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
146 USE_STR2IND=0
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
147
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
148 SUFFIX=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
149
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
150 # allow the user to override these defaults
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
151
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
152 shift
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
153 shift
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
154 while [ $# != 0 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
155 do
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
156 eval "$1"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
157 shift
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
158 done
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
159
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
160 BUILD_DIR="build-$TARGET-$CONFIG$SUFFIX"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
161
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
162 echo "Building configuration $CONFIG for target $TARGET in $BUILD_DIR"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
163
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
164 if [ "$clean_flag" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
165 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
166 rm -rf $BUILD_DIR
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
167 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
168 mkdir -p $BUILD_DIR
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
169
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
170 : > $BUILD_DIR/lcfgen
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
171
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
172 # shell functions to be used in the configuration recipe
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
173
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
174 build_lib() {
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
175 if [ $# != 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
176 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
177 echo "Error: build_lib takes 1 argument" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
178 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
179 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
180 scripts/mk-component.sh "$1"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
181 SUBDIR="$SUBDIR $1"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
182 current_lib=$1/$1.lib
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
183 LIBS="$LIBS $current_lib"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
184 }
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
185
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
186 blob_lib() {
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
187 if [ $# != 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
188 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
189 echo "Error: blob_lib takes 1 argument" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
190 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
191 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
192 current_lib="../blobs/$1.lib"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
193 LIBS="$LIBS $current_lib"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
194 }
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
195
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
196 cache_lib() {
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
197 if [ $# != 1 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
198 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
199 echo "Error: cache_lib takes 1 argument" 1>&2
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
200 exit 1
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
201 fi
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
202 current_lib="../cache/$1.lib"
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
203 LIBS="$LIBS $current_lib"
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
204 }
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
205
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
206 lib_link_magic() {
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
207 if [ $# != 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
208 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
209 echo "Error: lib_link_magic takes 1 argument" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
210 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
211 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
212 if [ -z "$current_lib" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
213 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
214 echo "Error: lib_link_magic called before build_lib or blob_lib" 1>&2
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
215 exit 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
216 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
217 SPECIAL_LINK_LIBS="$SPECIAL_LINK_LIBS $current_lib"
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
218 echo "$1" >> $BUILD_DIR/lcfgen
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
219 }
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
220
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
221 # invoke the configuration recipe
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
222
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
223 export BUILD_DIR TARGET USE_STR2IND
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
224 export CHIPSET DSP RF
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
225 export AMR L1_DYN_DSP_DWNLD L1_VOICE_MEMO_AMR MELODY_E2 SPEECH_RECO
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
226 export DISABLE_SLEEP
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
227 export FCHG_STATE R2D_STATE
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
228 export GPRS MMI SRVC RVTMUX_ON_MODEM
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
229 export R2D_EMBEDDED_LCD UI_CONFIG
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
230 export ALLOW_CSIM_GSM SERIAL_DYNAMIC_SWITCH TR_BAUD_CONFIG
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
231 export TI_PROFILER TRACEMASK_IN_FFS
38
e58a5bb12de4 experimental support for GPF memory supervision
Mychaela Falconia <falcon@freecalypso.org>
parents: 34
diff changeset
232 export MEMSUPER OSL
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
233
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
234 scripts/config-headers.sh
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
235
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
236 SUBDIR=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
237 LIBS=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
238 SPECIAL_LINK_LIBS=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
239 current_lib=
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
240
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
241 if [ "$USE_CACHE" = 1 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
242 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
243 cache_lib ccddata
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
244 else
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
245 build_lib ccddata
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
246 fi
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
247
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
248 # ACI libs
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
249 build_lib aci
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
250 build_lib aciext
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
251 build_lib aci_dti_mng
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
252 build_lib atiext
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
253 build_lib comlib
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
254
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
255 if [ "$GPRS" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
256 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
257 build_lib config_gprs_fl
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
258 build_lib config_gprs_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
259 else
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
260 build_lib config_gsm_fl
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
261 build_lib config_gsm_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
262 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
263 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
264
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
265 # UI layers
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
266 if [ "$MMI" = 2 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
267 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
268 build_lib bmi
43
01a8b04242af configure.sh: icn component is needed only for bigcolor
Mychaela Falconia <falcon@freecalypso.org>
parents: 42
diff changeset
269 if [ "$UI_CONFIG" = bigcolor ]
01a8b04242af configure.sh: icn component is needed only for bigcolor
Mychaela Falconia <falcon@freecalypso.org>
parents: 42
diff changeset
270 then
01a8b04242af configure.sh: icn component is needed only for bigcolor
Mychaela Falconia <falcon@freecalypso.org>
parents: 42
diff changeset
271 build_lib icn
01a8b04242af configure.sh: icn component is needed only for bigcolor
Mychaela Falconia <falcon@freecalypso.org>
parents: 42
diff changeset
272 fi
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
273 build_lib mfw
235
ee04ca45053d config system: add FCBM
Mychaela Falconia <falcon@freecalypso.org>
parents: 43
diff changeset
274 build_lib fcbm
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
275 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
276
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
277 # G23M protocol stack libs
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
278 build_lib alr
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
279 build_lib cc
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
280 build_lib dl
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
281 build_lib dti
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
282 build_lib l1_pei
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
283 build_lib mm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
284 build_lib rr
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
285 build_lib sim_b_lib
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
286 build_lib sms
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
287 build_lib ss
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
288 build_lib uart_b_lib
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
289
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
290 # fax and data
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
291 if [ "$SRVC" != 0 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
292 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
293 build_lib l2r
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
294 build_lib ra
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
295 build_lib rlp
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
296 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
297
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
298 # fax specific
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
299 if [ "$SRVC" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
300 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
301 build_lib fad
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
302 build_lib t30
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
303 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
304
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
305 # GPRS specific
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
306 if [ "$GPRS" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
307 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
308 build_lib cci
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
309 build_lib cci_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
310 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
311 build_lib cl
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
312 build_lib gmm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
313 build_lib grlc
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
314 build_lib grlc_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
315 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
316 build_lib grr
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
317 build_lib llc
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
318 build_lib sm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
319 build_lib sndcp
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
320 build_lib ppp
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
321 build_lib ppp_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
322 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
323 build_lib upm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
324 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
325
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
326 # Condat drivers
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
327 build_lib gdi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
328
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
329 # GPF
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
330
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
331 if [ "$USE_CACHE" = 1 -a "$MEMSUPER" = 0 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
332 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
333 cache_lib ccd_na7_db
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
334 elif [ "$USE_CACHE" = 1 -a "$MEMSUPER" = 2 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
335 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
336 cache_lib ccd_na7_db_ps
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
337 else
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
338 build_lib ccd
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
339 fi
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
340
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
341 if [ "$USE_CACHE" = 1 -a "$MEMSUPER" = 0 -a "$OSL" = 0 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
342 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
343 cache_lib frame_na7_db_fl
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
344 cache_lib frame_na7_db_ir
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
345 elif [ "$USE_CACHE" = 1 -a "$MEMSUPER" = 2 -a "$OSL" = 0 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
346 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
347 cache_lib frame_na7_db_ps_fl
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
348 cache_lib frame_na7_db_ps_ir
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
349 else
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
350 build_lib frame_fl
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
351 build_lib frame_ir
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
352 fi
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
353 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
354
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
355 if [ "$USE_CACHE" = 1 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
356 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
357 cache_lib misc_na7_db_fl
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
358 cache_lib misc_na7_db_ir
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
359 else
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
360 build_lib misc_fl
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
361 build_lib misc_ir
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
362 fi
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
363 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
364
38
e58a5bb12de4 experimental support for GPF memory supervision
Mychaela Falconia <falcon@freecalypso.org>
parents: 34
diff changeset
365 if [ "$OSX" = 1 -o "$MEMSUPER" != 0 ]
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
366 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
367 build_lib osx
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
368 else
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
369 blob_lib osx_na7_db
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
370 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
371 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
372
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
373 build_lib tif_fl
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
374 build_lib tif_ir
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
375 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
376
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
377 # core drivers
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
378 build_lib drivers_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
379
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
380 # Layer 1
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
381 build_lib tpudrv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
382 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
383 build_lib l1_ext
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
384 lib_link_magic '(BSS_LIBS (.l1s_global))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
385 build_lib l1_int
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
386 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
387 build_lib l1_custom_ext
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
388 build_lib l1_custom_int
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
389 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
390
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
391 build_lib riviera_core_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
392 build_lib riviera_cust_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
393
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
394 # services
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
395 build_lib audio
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
396 build_lib audio_bgd
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
397 build_lib cst
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
398 build_lib dar
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
399 build_lib dar_gbl_var
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
400 lib_link_magic '(BSS_DAR_LIB (.bss))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
401 build_lib etm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
402 build_lib lls
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
403
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
404 # app drivers
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
405 build_lib abb
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
406 build_lib buzzer
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
407 if [ "$FCHG_STATE" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
408 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
409 build_lib fchg
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
410 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
411 build_lib ffs
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
412 build_lib ffs_drv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
413 build_lib ffs_pcm
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
414 build_lib kpd
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
415 build_lib power
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
416 if [ "$R2D_STATE" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
417 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
418 build_lib r2d_drv_custom_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
419 build_lib r2d_drv_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
420 build_lib r2d_drv_int_ram
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
421 lib_link_magic '(CONST_LIBS (.text, .r2dlcd))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
422 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
423 build_lib rtc_drv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
424 build_lib sim_drv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
425 build_lib spi_drv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
426 build_lib uart_drv
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
427
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
428 # system glue
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
429 build_lib main
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
430 build_lib bootloader
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
431 lib_link_magic '(CONST_BOOT_LIB (.const, .text, .text:v$3) BSS_BOOT_LIB (.bss))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
432
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
433 # Nucleus
42
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
434 if [ "$USE_CACHE" = 1 ]
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
435 then
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
436 cache_lib nucleus_flash
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
437 cache_lib nucleus_intram
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
438 else
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
439 build_lib nucleus_flash
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
440 build_lib nucleus_intram
dd2ad0037425 configure.sh: USE_CACHE mechanism implemented
Mychaela Falconia <falcon@freecalypso.org>
parents: 38
diff changeset
441 fi
34
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
442 lib_link_magic '(BSS_LIBS (.bss) CONST_LIBS (.text, .const))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
443
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
444 # TI's libc/libgcc equivalent
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
445 blob_lib rts16le_flash
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
446 blob_lib rts16le_int_ram
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
447 lib_link_magic '(BSS_LIBS (.bss))'
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
448
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
449 # generate the top level Makefile!
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
450
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
451 helpers/makeline def CONFIG_NAME "$CONFIG$SUFFIX" > $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
452 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
453 helpers/makeline def TARGET $TARGET >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
454 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
455 helpers/makeline def SUBDIR $SUBDIR >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
456 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
457 helpers/makeline def LIBS $LIBS >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
458 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
459 helpers/makeline def SPECIAL_LINK_LIBS $SPECIAL_LINK_LIBS >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
460 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
461 helpers/makeline def LINK_SCRIPT_SRC ../$LINK_SCRIPT_SRC >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
462 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
463
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
464 if [ -n "$RAM_LINK_SCRIPT_SRC" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
465 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
466 helpers/makeline def RAM_LINK_SCRIPT_SRC ../$RAM_LINK_SCRIPT_SRC \
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
467 >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
468 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
469 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
470
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
471 helpers/makeline def FLASH_BASE_ADDR $FLASH_BASE_ADDR >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
472 helpers/makeline def FLASH_SECTOR_SIZE $FLASH_SECTOR_SIZE >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
473 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
474
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
475 if [ "$USE_STR2IND" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
476 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
477 helpers/makeline def STR2IND_OBJ str2ind.obj >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
478 else
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
479 echo 'STR2IND_OBJ=' >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
480 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
481 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
482
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
483 cat makefile-frags/first-part >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
484
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
485 if [ "$USE_STR2IND" = 1 ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
486 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
487 cat makefile-frags/str2ind >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
488 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
489
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
490 cat makefile-frags/link-steps >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
491
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
492 case "$TARGET" in
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
493 c11x|c139|j100)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
494 cat makefile-frags/m0-to-bin-c139 >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
495 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
496 c155)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
497 cat makefile-frags/m0-to-bin-c155 >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
498 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
499 *)
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
500 cat makefile-frags/m0-to-bin-std >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
501 ;;
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
502 esac
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
503
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
504 cat makefile-frags/flash-script-gen >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
505
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
506 if [ -n "$RAM_LINK_SCRIPT_SRC" ]
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
507 then
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
508 cat makefile-frags/ram-link-steps >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
509 fi
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
510
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
511 cat makefile-frags/clean-always >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
512 echo >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
513 echo 'FRC:' >> $BUILD_DIR/Makefile
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
514
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
515 # All done!
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
516
32a6a9833bd6 configure.sh: putting it all together
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
517 echo "Run make in $BUILD_DIR to compile the firmware"