3 # Copyright 2007 Free Software Foundation, Inc.
5 # This program is free software: you can redistribute it and/or modify
6 # it under the terms of the GNU General Public License as published by
7 # the Free Software Foundation, either version 3 of the License, or
8 # (at your option) any later version.
10 # This program is distributed in the hope that it will be useful,
11 # but WITHOUT ANY WARRANTY; without even the implied warranty of
12 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 # GNU General Public License for more details.
15 # You should have received a copy of the GNU General Public License
16 # along with this program. If not, see <http://www.gnu.org/licenses/>.
19 STD_INCLUDES = -I$(top_srcdir)/include -I$(top_srcdir)/lib
21 #HAL_IO = -DHAL_IO_USES_DBOARD_PINS
22 HAL_IO = -DHAL_IO_USES_UART
24 AM_CPPFLAGS = $(HAL_IO) $(STD_INCLUDES)
26 STD_CFLAGS = --std=gnu99 -Wall -Werror-implicit-function-declaration -mxl-soft-div -msoft-float
28 AM_CFLAGS = $(STD_CFLAGS) -mxl-soft-mul -mxl-barrel-shift
29 #AM_CFLAGS = $(STD_CFLAGS) -mxl-soft-mul -mxl-barrel-shift -mxl-gp-opt -G 16384
32 #LINKER_SCRIPT = $(top_srcdir)/lib/microblaze.ld
33 #AM_LDFLAGS = -Wl,-T,$(LINKER_SCRIPT) -Wl,-defsym -Wl,_STACK_SIZE=1024
34 #AM_LDFLAGS = -Wl,-T,$(LINKER_SCRIPT) -Wl,-Map -Wl,$@.map
35 #AM_LDFLAGS = -Wl,-T,$(LINKER_SCRIPT)
36 AM_LDFLAGS = -Wl,-Map -Wl,$@.map -Wl,-defsym -Wl,_STACK_SIZE=3072
37 #AM_LDFLAGS = -Wl,-defsym -Wl,_STACK_SIZE=2048
41 mb-objcopy -O binary $< $@
44 mb-objdump -DSC $< > $@
47 hexdump -v -e'1/1 "%.2X\n"' $< > $@
53 BINS = $(noinst_PROGRAMS:=.bin)
54 ROMS = $(noinst_PROGRAMS:=.rom)
55 DUMPS = $(noinst_PROGRAMS:=.dump)
57 noinst_DATA = $(BINS) $(ROMS) $(DUMPS)
59 CLEANFILES = $(ROMS) $(DUMPS) $(BINS)