Commit | Line | Data |
---|---|---|
4fa134be ILT |
1 | # Makefile template for Configure for the MIPS simulator. |
2 | # Written by Cygnus Support. | |
3 | ||
19c5af72 DE |
4 | ## COMMON_PRE_CONFIG_FRAG |
5 | ||
fafce69a AC |
6 | srcdir=@srcdir@ |
7 | srcroot=$(srcdir)/../../ | |
8 | ||
9 | SIM_OBJS = interp.o \ | |
10 | sim-load.o \ | |
11 | sim-utils.o \ | |
12 | sim-hload.o \ | |
13 | sim-io.o \ | |
14 | sim-config.o \ | |
15 | sim-endian.o \ | |
16 | sim-engine.o \ | |
17 | sim-stop.o \ | |
18 | sim-resume.o \ | |
19 | sim-reason.o \ | |
20 | sim-events.o \ | |
21 | sim-module.o \ | |
22 | sim-trace.o \ | |
23 | sim-options.o \ | |
24 | sim-core.o \ | |
25 | sim-watch.o | |
26 | ||
27 | # List of flags to always pass to $(CC). | |
28 | SIM_WARNINGS=@sim_warnings@ | |
29 | SIM_ENDIAN=@sim_endian@ | |
30 | SIM_HOSTENDIAN=@sim_hostendian@ | |
31 | SIM_INLINE=@sim_inline@ | |
32 | ||
295dbbe4 SG |
33 | # FIXME: Hack to find syscall.h? Better support for syscall.h |
34 | # is in progress. | |
fafce69a AC |
35 | SIM_EXTRA_CFLAGS = \ |
36 | $(SIM_WARNINGS) \ | |
37 | $(SIM_ENDIAN) \ | |
38 | $(SIM_HOSTENDIAN) \ | |
39 | $(SIM_INLINE) \ | |
40 | -I$(srcdir)/../../newlib/libc/sys/idt | |
41 | ||
295dbbe4 | 42 | SIM_EXTRA_CLEAN = clean-extra |
4fa134be | 43 | |
fafce69a AC |
44 | # List of main object files for `run'. |
45 | SIM_RUN_OBJS = nrun.o | |
46 | ||
47 | ||
48 | ||
19c5af72 | 49 | ## COMMON_POST_CONFIG_FRAG |
4fa134be | 50 | |
fafce69a | 51 | interp.o: $(srcdir)/interp.c engine.c $(srcdir)/support.h config.h |
4fa134be | 52 | |
295dbbe4 SG |
53 | engine.c: gencode |
54 | ./gencode @SIMCONF@ > $@ | |
4fa134be | 55 | |
295dbbe4 SG |
56 | gencode: gencode.o getopt.o getopt1.o |
57 | $(CC_FOR_BUILD) -o $@ gencode.o getopt.o getopt1.o | |
4fa134be | 58 | |
295dbbe4 SG |
59 | gencode.o: $(srcdir)/gencode.c |
60 | $(CC_FOR_BUILD) -c -g -I${srcroot}/include $(srcdir)/gencode.c | |
61 | getopt.o: $(srcdir)/../../libiberty/getopt.c | |
62 | $(CC_FOR_BUILD) -c -g -I${srcroot}/include $(srcdir)/../../libiberty/getopt.c | |
63 | getopt1.o: $(srcdir)/../../libiberty/getopt1.c | |
64 | $(CC_FOR_BUILD) -c -g -I${srcroot}/include $(srcdir)/../../libiberty/getopt1.c | |
4fa134be | 65 | |
295dbbe4 SG |
66 | clean-extra: |
67 | rm -f gencode engine.c |