diff options
author | Linus Nielsen Feltzing <linus@haxx.se> | 2002-05-17 07:52:28 +0000 |
---|---|---|
committer | Linus Nielsen Feltzing <linus@haxx.se> | 2002-05-17 07:52:28 +0000 |
commit | 82b08d0bdb81562486be52654f4046592b659865 (patch) | |
tree | b38ca99ad3c31fb954d8063c800ddaf1048a7629 /firmware | |
parent | afd30bb4cd64077274f90c0154ba74022a0cfdc3 (diff) | |
download | rockbox-82b08d0bdb81562486be52654f4046592b659865.tar.gz rockbox-82b08d0bdb81562486be52654f4046592b659865.zip |
Added DEBUG option and made thread.o special
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@610 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r-- | firmware/Makefile | 20 |
1 files changed, 17 insertions, 3 deletions
diff --git a/firmware/Makefile b/firmware/Makefile index 62bb9f98da..25d1b1e29c 100644 --- a/firmware/Makefile +++ b/firmware/Makefile | |||
@@ -20,15 +20,25 @@ TARGET = -DARCHOS_PLAYER=1 | |||
20 | #TARGET = -DARCHOS_PLAYER_OLD=1 | 20 | #TARGET = -DARCHOS_PLAYER_OLD=1 |
21 | #TARGET = -DARCHOS_RECORDER=1 | 21 | #TARGET = -DARCHOS_RECORDER=1 |
22 | 22 | ||
23 | CFLAGS = -Os -W -Wall -m1 -nostdlib -Wstrict-prototypes -fomit-frame-pointer -fschedule-insns $(INCLUDES) $(TARGET) -DDEBUG | 23 | CFLAGS = -W -Wall -m1 -nostdlib -Wstrict-prototypes $(INCLUDES) $(TARGET) |
24 | |||
25 | ifdef DEBUG | ||
26 | CFLAGS += -g -DDEBUG | ||
27 | else | ||
28 | CFLAGS += -O -fomit-frame-pointer -fschedule-insns | ||
29 | endif | ||
30 | |||
24 | AFLAGS += -small -relax | 31 | AFLAGS += -small -relax |
25 | 32 | ||
26 | SRC := $(wildcard drivers/*.c common/*.c malloc/*.c *.c) | 33 | SRC := $(wildcard drivers/*.c common/*.c malloc/*.c *.c) |
27 | OBJS := $(SRC:%.c=%.o) crt0.o | 34 | EXCLUDED_SRC := thread.c |
35 | |||
36 | SRC := $(filter-out $(EXCLUDED_SRC),$(SRC)) | ||
37 | |||
38 | OBJS := $(SRC:%.c=%.o) $(EXCLUDED_SRC:%.c=%.o) crt0.o | ||
28 | DEPS:=.deps | 39 | DEPS:=.deps |
29 | DEPDIRS:=$(DEPS) $(DEPS)/drivers $(DEPS)/common $(DEPS)/malloc | 40 | DEPDIRS:=$(DEPS) $(DEPS)/drivers $(DEPS)/common $(DEPS)/malloc |
30 | 41 | ||
31 | |||
32 | librockbox.a: $(OBJS) | 42 | librockbox.a: $(OBJS) |
33 | $(AR) ruv $@ $+ | 43 | $(AR) ruv $@ $+ |
34 | 44 | ||
@@ -44,3 +54,7 @@ $(DEPS)/%.d: %.c | |||
44 | [ -s $@ ] || rm -f $@' | 54 | [ -s $@ ] || rm -f $@' |
45 | 55 | ||
46 | -include $(SRC:%.c=$(DEPS)/%.d) | 56 | -include $(SRC:%.c=$(DEPS)/%.d) |
57 | |||
58 | # Special targets | ||
59 | thread.o: thread.c thread.h | ||
60 | $(CC) -c -O -fomit-frame-pointer $(CFLAGS) $< | ||