2 # $Id: rules.cbl,v 1.4 2005/04/20 11:18:54 starvik Exp $
7 ifeq ($(findstring _noleds,$(IMAGE)),_noleds)
15 DEFS := -DUSE_LEDS=$(USE_LEDS)
16 CFLAGS := -Os -Wall -Wmissing-prototypes -W -Wa,-N -nostdinc $(INCS) $(DEFS) -MMD
18 LNFLAGS := -Wl,--section-start,.startup=0x380000f0 -nostdlib -Os -Wl,-T../src/ldscript
19 CC := cris-axis-elf-gcc
21 OUT := $(patsubst %.ima,%.out,$(IMAGE))
23 OBJS = crt0.o common_init.o
24 ifeq ($(findstring net,$(IMAGE)),net)
29 OBJS += common.o flash.o hwregs.o e100boot_version.o
33 $(OUT): $(OBJS) ldscript
34 $(CC) -o $@ $(LNFLAGS) $(OBJS)
38 @find $@ -printf '# Size of image $@ is %s bytes.\n\n'
40 $(OBJS): ../rules.cbl Makefile
42 # We don't want this to be a dummy and be recreated every time we build,
43 # only after a make clean
45 @echo "Generating version file....."
46 @echo 'char e100boot_version[] = "This bootloader was built by '`id -u -n`' on '`date`'.\r\n";' > $@
51 rm -rf *.o *.d *.out *.ima deps e100boot_version.c
53 ifneq ($(MAKECMDGOALS),clean)