1 # Makefile template for Configure for the MIPS simulator.
2 # Written by Cygnus Support.
4 ## COMMON_PRE_CONFIG_FRAG
7 srcroot
=$(srcdir)/..
/..
/
9 # Object files created by various simulator generators.
37 MIPS_EXTRA_OBJS
= @mips_extra_objs@
38 MIPS_EXTRA_LIBS
= @mips_extra_libs@
41 $(SIM_@sim_gen@_OBJ
) \
42 $(SIM_NEW_COMMON_OBJS
) \
53 # List of flags to always pass to $(CC).
54 SIM_SUBTARGET
=@SIM_SUBTARGET@
55 SIM_EXTRA_CFLAGS
= $(SIM_SUBTARGET
)
57 SIM_EXTRA_CLEAN
= clean-extra
59 SIM_EXTRA_ALL
= $(SIM_@sim_gen@_ALL
)
61 SIM_EXTRA_LIBS
= $(MIPS_EXTRA_LIBS
)
63 # List of main object files for `run'.
68 ## COMMON_POST_CONFIG_FRAG
70 interp.o
: $(srcdir)/interp.c config.h sim-main.h itable.h
76 IGEN_TRACE
= # -G omit-line-numbers # -G trace-rule-selection -G trace-rule-rejection -G trace-entries # -G trace-all
77 IGEN_INSN
=$(srcdir)/mips.igen
78 IGEN_DC
=$(srcdir)/mips.dc
79 M16_DC
=$(srcdir)/m16.dc
85 # NB: Since these can be built by a number of generators, care
86 # must be taken to ensure that they are only dependant on
87 # one of those generators.
88 BUILT_SRC_FROM_GEN
= \
92 SIM_IGEN_ALL
= tmp-igen
95 $(BUILT_SRC_FROM_GEN
): $(SIM_@sim_gen@_ALL
)
99 BUILT_SRC_FROM_IGEN
= \
114 $(BUILT_SRC_FROM_IGEN
): tmp-igen
116 tmp-igen
: $(IGEN_INSN
) $(IGEN_DC
) ..
/igen
/igen
$(IGEN_INCLUDE
)
117 cd ..
/igen
&& $(MAKE
)
124 -G gen-direct-access \
131 -n icache.h
-hc tmp-icache.h \
132 -n icache.c
-c tmp-icache.c \
133 -n semantics.h
-hs tmp-semantics.h \
134 -n semantics.c
-s tmp-semantics.c \
135 -n idecode.h
-hd tmp-idecode.h \
136 -n idecode.c
-d tmp-idecode.c \
137 -n model.h
-hm tmp-model.h \
138 -n model.c
-m tmp-model.c \
139 -n support.h
-hf tmp-support.h \
140 -n support.c
-f tmp-support.c \
141 -n itable.h
-ht tmp-itable.h \
142 -n itable.c
-t tmp-itable.c \
143 -n engine.h
-he tmp-engine.h \
144 -n engine.c
-e tmp-engine.c \
145 -n irun.c
-r tmp-irun.c
146 $(srcdir)/..
/..
/move-if-change tmp-icache.h icache.h
147 $(srcdir)/..
/..
/move-if-change tmp-icache.c icache.c
148 $(srcdir)/..
/..
/move-if-change tmp-idecode.h idecode.h
149 $(srcdir)/..
/..
/move-if-change tmp-idecode.c idecode.c
150 $(srcdir)/..
/..
/move-if-change tmp-semantics.h semantics.h
151 $(srcdir)/..
/..
/move-if-change tmp-semantics.c semantics.c
152 $(srcdir)/..
/..
/move-if-change tmp-model.h model.h
153 $(srcdir)/..
/..
/move-if-change tmp-model.c model.c
154 $(srcdir)/..
/..
/move-if-change tmp-support.h support.h
155 $(srcdir)/..
/..
/move-if-change tmp-support.c support.c
156 $(srcdir)/..
/..
/move-if-change tmp-itable.h itable.h
157 $(srcdir)/..
/..
/move-if-change tmp-itable.c itable.c
158 $(srcdir)/..
/..
/move-if-change tmp-engine.h engine.h
159 $(srcdir)/..
/..
/move-if-change tmp-engine.c engine.c
160 $(srcdir)/..
/..
/move-if-change tmp-irun.c irun.c
163 semantics.o
: sim-main.h semantics.c
$(SIM_EXTRA_DEPS
)
164 engine.o
: sim-main.h engine.c
$(SIM_EXTRA_DEPS
)
165 support.o
: sim-main.h support.c
$(SIM_EXTRA_DEPS
)
166 idecode.o
: sim-main.h idecode.c
$(SIM_EXTRA_DEPS
)
167 itable.o
: sim-main.h itable.c
$(SIM_EXTRA_DEPS
)
172 BUILT_SRC_FROM_M16
= \
195 $(BUILT_SRC_FROM_M16
): tmp-m16
197 tmp-m16
: $(IGEN_INSN
) $(IGEN_DC
) ..
/igen
/igen
$(IGEN_INCLUDE
)
198 cd ..
/igen
&& $(MAKE
)
205 -G gen-direct-access \
213 -n m16_icache.h
-hc tmp-icache.h \
214 -n m16_icache.c
-c tmp-icache.c \
215 -n m16_semantics.h
-hs tmp-semantics.h \
216 -n m16_semantics.c
-s tmp-semantics.c \
217 -n m16_idecode.h
-hd tmp-idecode.h \
218 -n m16_idecode.c
-d tmp-idecode.c \
219 -n m16_model.h
-hm tmp-model.h \
220 -n m16_model.c
-m tmp-model.c \
221 -n m16_support.h
-hf tmp-support.h \
222 -n m16_support.c
-f tmp-support.c \
224 $(srcdir)/..
/..
/move-if-change tmp-icache.h m16_icache.h
225 $(srcdir)/..
/..
/move-if-change tmp-icache.c m16_icache.c
226 $(srcdir)/..
/..
/move-if-change tmp-idecode.h m16_idecode.h
227 $(srcdir)/..
/..
/move-if-change tmp-idecode.c m16_idecode.c
228 $(srcdir)/..
/..
/move-if-change tmp-semantics.h m16_semantics.h
229 $(srcdir)/..
/..
/move-if-change tmp-semantics.c m16_semantics.c
230 $(srcdir)/..
/..
/move-if-change tmp-model.h m16_model.h
231 $(srcdir)/..
/..
/move-if-change tmp-model.c m16_model.c
232 $(srcdir)/..
/..
/move-if-change tmp-support.h m16_support.h
233 $(srcdir)/..
/..
/move-if-change tmp-support.c m16_support.c
240 -G gen-direct-access \
248 -n m32_icache.h
-hc tmp-icache.h \
249 -n m32_icache.c
-c tmp-icache.c \
250 -n m32_semantics.h
-hs tmp-semantics.h \
251 -n m32_semantics.c
-s tmp-semantics.c \
252 -n m32_idecode.h
-hd tmp-idecode.h \
253 -n m32_idecode.c
-d tmp-idecode.c \
254 -n m32_model.h
-hm tmp-model.h \
255 -n m32_model.c
-m tmp-model.c \
256 -n m32_support.h
-hf tmp-support.h \
257 -n m32_support.c
-f tmp-support.c \
259 $(srcdir)/..
/..
/move-if-change tmp-icache.h m32_icache.h
260 $(srcdir)/..
/..
/move-if-change tmp-icache.c m32_icache.c
261 $(srcdir)/..
/..
/move-if-change tmp-idecode.h m32_idecode.h
262 $(srcdir)/..
/..
/move-if-change tmp-idecode.c m32_idecode.c
263 $(srcdir)/..
/..
/move-if-change tmp-semantics.h m32_semantics.h
264 $(srcdir)/..
/..
/move-if-change tmp-semantics.c m32_semantics.c
265 $(srcdir)/..
/..
/move-if-change tmp-model.h m32_model.h
266 $(srcdir)/..
/..
/move-if-change tmp-model.c m32_model.c
267 $(srcdir)/..
/..
/move-if-change tmp-support.h m32_support.h
268 $(srcdir)/..
/..
/move-if-change tmp-support.c m32_support.c
275 @sim_igen_flags@ @sim_m16_flags@ \
276 -G gen-direct-access \
279 -n itable.h
-ht tmp-itable.h \
280 -n itable.c
-t tmp-itable.c \
282 $(srcdir)/..
/..
/move-if-change tmp-itable.h itable.h
283 $(srcdir)/..
/..
/move-if-change tmp-itable.c itable.c
288 rm -f
$(BUILT_SRC_FROM_GEN
)
289 rm -f
$(BUILT_SRC_FROM_IGEN
)
290 rm -f
$(BUILT_SRC_FROM_M16
)
292 rm -f m16
*.o m32
*.o itable
*.o