1 | ## |
---|
2 | ## $Id$ |
---|
3 | ## |
---|
4 | |
---|
5 | AUTOMAKE_OPTIONS = foreign 1.4 |
---|
6 | |
---|
7 | VPATH = @srcdir@:@srcdir@/../../../shared:@srcdir@/../../shared/console:@srcdir@/../../shared/bootloader |
---|
8 | |
---|
9 | LIB = $(ARCH)/bootloader.o |
---|
10 | LDS = ppcboot.lds |
---|
11 | |
---|
12 | C_FILES = misc.c pci.c zlib.c mm.c em86.c polled_io.c lib.c |
---|
13 | C_O_FILES = $(C_FILES:%.c=$(ARCH)/%.o) |
---|
14 | |
---|
15 | H_FILES = bootldr.h zlib.h pci.h |
---|
16 | |
---|
17 | S_FILES = head.S exception.S em86real.S |
---|
18 | S_O_FILES = $(S_FILES:%.S=$(ARCH)/%.o) |
---|
19 | |
---|
20 | OBJS = $(S_O_FILES) $(C_O_FILES) |
---|
21 | |
---|
22 | include $(RTEMS_ROOT)/make/custom/@RTEMS_BSP@.cfg |
---|
23 | include $(top_srcdir)/../../../../../../automake/compile.am |
---|
24 | include $(top_srcdir)/../../../../../../automake/lib.am |
---|
25 | |
---|
26 | # |
---|
27 | # (OPTIONAL) Add local stuff here using += |
---|
28 | # |
---|
29 | |
---|
30 | ## FIXME: |
---|
31 | ## ASFLAGS = -mrelocatable |
---|
32 | CFLAGS_DEBUG_V = $(CFLAGS_OPTIMIZE_V) |
---|
33 | |
---|
34 | AM_CPPFLAGS += -D__BOOT__ -DDEBUG -mrelocatable |
---|
35 | AM_CFLAGS += -msoft-float -mstrict-align -fno-builtin -Wall -mmultiple \ |
---|
36 | -mstring -O2 -fomit-frame-pointer -ffixed-r13 -mno-sdata |
---|
37 | |
---|
38 | CLEANFILES += bootloader.o |
---|
39 | |
---|
40 | # |
---|
41 | # CAUTION : |
---|
42 | # |
---|
43 | # As we use very specific compilation options in this directory |
---|
44 | # we shall not use any other code. This includes the newlib libc.a |
---|
45 | # as well as other code located in .o files in mcp750 directory. |
---|
46 | # |
---|
47 | # NEVER remove lib.c. You have been warned... |
---|
48 | # |
---|
49 | |
---|
50 | $(LIB) : $(OBJS) |
---|
51 | $(LD) -r -o $(ARCH)/bootloader.o $(OBJS) |
---|
52 | $(NM) $(ARCH)/bootloader.o | grep ' U ' |
---|
53 | echo "Every symbol listed should be defined in @srcdir@/ppcboot.lds" |
---|
54 | |
---|
55 | $(PROJECT_RELEASE)/lib/bootloader.o : $(LIB) |
---|
56 | $(INSTALL_DATA) $< $@ |
---|
57 | |
---|
58 | $(PROJECT_RELEASE)/lib/ppcboot.lds : $(LDS) |
---|
59 | $(INSTALL_DATA) $< $@ |
---|
60 | |
---|
61 | all-local: $(ARCH) $(PROJECT_RELEASE)/lib/bootloader.o $(PROJECT_RELEASE)/lib/ppcboot.lds |
---|
62 | |
---|
63 | include $(top_srcdir)/../../../../../../automake/local.am |
---|