1 | # |
---|
2 | # $Id$ |
---|
3 | # |
---|
4 | |
---|
5 | @SET_MAKE@ |
---|
6 | srcdir = @srcdir@ |
---|
7 | VPATH = @srcdir@ |
---|
8 | RTEMS_ROOT = @top_srcdir@ |
---|
9 | PROJECT_ROOT = @PROJECT_ROOT@ |
---|
10 | |
---|
11 | RELS=$(ARCH)/rtems-cpu.rel |
---|
12 | |
---|
13 | # C source names, if any, go here -- minus the .c |
---|
14 | C_PIECES=cpu cpu_asm cpu_isps rtems |
---|
15 | C_FILES=$(C_PIECES:%=%.c) |
---|
16 | C_O_FILES=$(C_PIECES:%=${ARCH}/%.o) |
---|
17 | |
---|
18 | H_FILES= \ |
---|
19 | $(srcdir)/cpu.h \ |
---|
20 | $(srcdir)/shtypes.h \ |
---|
21 | $(srcdir)/sh.h \ |
---|
22 | $(srcdir)/sh_io.h \ |
---|
23 | $(srcdir)/cpu_isps.h \ |
---|
24 | $(srcdir)/iosh7030.h |
---|
25 | |
---|
26 | # H_FILES that get installed externally |
---|
27 | # sh.h is handled separately |
---|
28 | EXTERNAL_H_FILES = \ |
---|
29 | $(srcdir)/asm.h |
---|
30 | |
---|
31 | # Assembly source names, if any, go here -- minus the .s |
---|
32 | # Normally cpu_asm and rtems are assembly files |
---|
33 | S_PIECES= |
---|
34 | S_FILES=$(S_PIECES:%=%.s) |
---|
35 | S_O_FILES=$(S_FILES:%.s=${ARCH}/%.o) |
---|
36 | |
---|
37 | SRCS=$(C_FILES) $(CC_FILES) $(H_FILES) $(S_FILES) $(EXTERNAL_H_FILES) |
---|
38 | OBJS=$(C_O_FILES) $(CC_O_FILES) $(S_O_FILES) |
---|
39 | |
---|
40 | include $(RTEMS_ROOT)/make/custom/$(RTEMS_BSP).cfg |
---|
41 | include $(RTEMS_ROOT)/make/leaf.cfg |
---|
42 | |
---|
43 | # |
---|
44 | # (OPTIONAL) Add local stuff here using += |
---|
45 | # |
---|
46 | |
---|
47 | DEFINES += |
---|
48 | CPPFLAGS += |
---|
49 | CFLAGS += $(CFLAGS_OS_V) |
---|
50 | |
---|
51 | LD_PATHS += |
---|
52 | LD_LIBS += |
---|
53 | LDFLAGS += |
---|
54 | |
---|
55 | # |
---|
56 | # Add your list of files to delete here. The config files |
---|
57 | # already know how to delete some stuff, so you may want |
---|
58 | # to just run 'make clean' first to see what gets missed. |
---|
59 | # 'make clobber' already includes 'make clean' |
---|
60 | # |
---|
61 | |
---|
62 | CLEAN_ADDITIONS += |
---|
63 | CLOBBER_ADDITIONS += |
---|
64 | |
---|
65 | all: ${ARCH} $(SRCS) preinstall $(OBJS) $(RELS) |
---|
66 | |
---|
67 | $(ARCH)/rtems-cpu.rel: $(OBJS) |
---|
68 | $(make-rel) |
---|
69 | |
---|
70 | # Install the program(s), appending _g or _p as appropriate. |
---|
71 | # for include files, just use $(INSTALL) |
---|
72 | install: all |
---|
73 | |
---|
74 | preinstall: $(PROJECT_INCLUDE)/rtems/score/targopts.h \ |
---|
75 | ${PROJECT_RELEASE}/lib/bsp_specs |
---|
76 | $(INSTALL) -m 444 ${H_FILES} $(PROJECT_INCLUDE)/rtems/score |
---|
77 | # we will share the basic cpu file |
---|
78 | $(INSTALL) -m 444 ${EXTERNAL_H_FILES} $(PROJECT_INCLUDE) |
---|
79 | |
---|
80 | $(PROJECT_INCLUDE)/rtems/score/targopts.h: $(ARCH)/targopts.h-tmp |
---|
81 | $(INSTALL) -m 444 $(ARCH)/targopts.h-tmp $@ |
---|
82 | |
---|
83 | # $(ARCH)/targopts.h-tmp rule is in leaf.cfg |
---|
84 | |
---|
85 | ${PROJECT_RELEASE}/lib/bsp_specs: $(ARCH)/bsp_specs.tmp |
---|
86 | $(INSTALL) -m 444 $(ARCH)/bsp_specs.tmp $@ |
---|
87 | |
---|
88 | # $(ARCH)/bsp_specs.tmp rule is in leaf.cfg |
---|