source: rtems/make/custom/mrm332.cfg @ d2d3482

4.104.114.84.9
Last change on this file since d2d3482 was d2d3482, checked in by Ralf Corsepius <ralf.corsepius@…>, on Jan 18, 2007 at 7:00:28 AM

Remove obsolete comments referring to gcc-2.8.

  • Property mode set to 100644
File size: 2.2 KB
Line 
1#
2#  Config file for the mrm332 BSP
3#
4#  $Id$
5#
6
7include $(RTEMS_ROOT)/make/custom/default.cfg
8
9RTEMS_CPU=m68k
10RTEMS_CPU_MODEL=m68332
11
12# This is the actual bsp directory used during the build process.
13RTEMS_BSP_FAMILY=mrm332
14
15#  This contains the compiler options necessary to select the CPU model
16#  and (hopefully) optimize for it.
17CPU_CFLAGS = -mcpu32
18
19# optimize flag: typically -O2
20CFLAGS_OPTIMIZE_V = -O4 -fomit-frame-pointer
21
22# The following are definitions of make-exe which will work using ld as
23# is currently required.
24
25ifeq ($(MRM_IN_ROM),yes)
26# Build a rommable image - move the .data section after the .text section
27# in the image.
28CPU_CFLAGS += -qnolinkcmds -T $(exec_prefix)/mrm332/lib/linkcmds_ROM
29
30#  This is a good way to get debug information.  The output file is large
31#  though and greatly slows the build process so only do this if needed.
32#       $(OBJDUMP) -dxC $(basename $@).nxe > $(basename $@).dump
33
34define make-exe
35        $(LINK.c) $(AM_CFLAGS) $(AM_LDFLAGS) -o $(basename $@).pxe \
36            $(LINK_OBJS) $(LINK_LIBS)
37        $(OBJCOPY) --adjust-section-vma \
38          .data=`m68k-rtems-objdump --section-headers $(basename $@).pxe | \
39          awk 'function h2d(x) { x=toupper(x); digits=length(x); s=0 ; \
40               for (p=digits; p>0; p--) \
41               s += (16^(p-1)) * ( index("0123456789ABCDEF",\
42                substr(x,1+digits-p,1)) -1 );\
43                return s } ;\
44                /\.text/ { base = $$4 ; size = $$3 };\
45                END { printf("0x%x", h2d(base) + h2d(size)) }'\
46               ` $(basename $@).pxe $(basename $@).nxe
47        $(OBJCOPY) -O srec $(basename $@).nxe $(basename $@).srec
48        sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
49            $(PACKHEX) > $(basename $@).exe
50        $(NM) -g -n $(basename $@).pxe > $(basename $@).pnum
51        $(NM) -g -n $(basename $@).nxe > $(basename $@).num
52        $(SIZE) $(basename $@).nxe
53endef
54else
55define make-exe
56        $(LINK.c) $(AM_CFLAGS) $(AM_LDFLAGS) -o $(basename $@).nxe \
57            $(LINK_OBJS) $(LINK_LIBS)
58        $(OBJCOPY) -O srec $(basename $@).nxe $(basename $@).srec
59#       m68k-rtems-objdump -dxC $(basename $@).nxe > $(basename $@).dump
60        sed -e 's/.$$//' -e '/^S0/d' $(basename $@).srec | \
61            $(PACKHEX) > $(basename $@).exe
62        $(NM) -g -n $(basename $@).nxe > $(basename $@).num
63        $(SIZE) $(basename $@).nxe
64endef
65endif
66
67# Miscellaneous additions go here
Note: See TracBrowser for help on using the repository browser.