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 |
---|
15 | C_FILES=$(C_PIECES:%=%.c) |
---|
16 | C_O_FILES=$(C_PIECES:%=${ARCH}/%.o) |
---|
17 | |
---|
18 | H_FILES=$(srcdir)/cpu.h $(srcdir)/i386.h $(srcdir)/i386types.h |
---|
19 | |
---|
20 | # H_FILES that get installed externally |
---|
21 | # i386.h is handled specially |
---|
22 | EXTERNAL_H_FILES = $(srcdir)/asm.h |
---|
23 | |
---|
24 | # Assembly source names, if any, go here -- minus the .S |
---|
25 | S_PIECES=cpu_asm rtems |
---|
26 | S_FILES=$(S_PIECES:%=%.S) |
---|
27 | S_O_FILES=$(S_FILES:%.S=${ARCH}/%.o) |
---|
28 | |
---|
29 | SRCS=$(C_FILES) $(CC_FILES) $(H_FILES) $(S_FILES) $(EXTERNAL_H_FILES) |
---|
30 | OBJS=$(C_O_FILES) $(CC_O_FILES) $(S_O_FILES) |
---|
31 | |
---|
32 | include $(RTEMS_ROOT)/make/custom/$(RTEMS_BSP).cfg |
---|
33 | include $(RTEMS_ROOT)/make/leaf.cfg |
---|
34 | |
---|
35 | # |
---|
36 | # (OPTIONAL) Add local stuff here using += |
---|
37 | # |
---|
38 | |
---|
39 | DEFINES += |
---|
40 | CPPFLAGS += |
---|
41 | CFLAGS += $(CFLAGS_OS_V) |
---|
42 | |
---|
43 | LD_PATHS += |
---|
44 | LD_LIBS += |
---|
45 | LDFLAGS += |
---|
46 | |
---|
47 | # |
---|
48 | # Add your list of files to delete here. The config files |
---|
49 | # already know how to delete some stuff, so you may want |
---|
50 | # to just run 'make clean' first to see what gets missed. |
---|
51 | # 'make clobber' already includes 'make clean' |
---|
52 | # |
---|
53 | |
---|
54 | CLEAN_ADDITIONS += |
---|
55 | CLOBBER_ADDITIONS += |
---|
56 | |
---|
57 | $(ARCH)/rtems-cpu.rel: $(OBJS) |
---|
58 | $(make-rel) |
---|
59 | |
---|
60 | all: ${ARCH} $(SRCS) preinstall $(OBJS) $(RELS) |
---|
61 | |
---|
62 | # Install the program(s), appending _g or _p as appropriate. |
---|
63 | # for include files, just use $(INSTALL) |
---|
64 | install: all |
---|
65 | |
---|
66 | preinstall: $(ARCH) \ |
---|
67 | ${PROJECT_RELEASE}/lib/bsp_specs |
---|
68 | $(INSTALL) -m 444 ${H_FILES} $(PROJECT_INCLUDE)/rtems/score |
---|
69 | # we will share the basic cpu file |
---|
70 | $(INSTALL) -m 444 ${EXTERNAL_H_FILES} $(PROJECT_INCLUDE) |
---|
71 | |
---|
72 | ${PROJECT_RELEASE}/lib/bsp_specs: $(ARCH)/bsp_specs.tmp |
---|
73 | $(INSTALL) -m 444 $(ARCH)/bsp_specs.tmp $@ |
---|
74 | |
---|
75 | # $(ARCH)/bsp_specs.tmp rule is in leaf.cfg |
---|