2011-05-11 21:18:46 +00:00
|
|
|
##########################################################################
|
|
|
|
# User configuration and firmware specific object files
|
|
|
|
##########################################################################
|
|
|
|
|
|
|
|
OBJS =
|
2011-05-13 13:20:08 +00:00
|
|
|
|
2011-05-11 21:18:46 +00:00
|
|
|
OBJS += display.o
|
|
|
|
OBJS += render.o
|
2011-05-14 20:23:55 +00:00
|
|
|
OBJS += decoder.o
|
2011-05-21 15:26:37 +00:00
|
|
|
OBJS += backlight.o
|
2011-05-11 21:18:46 +00:00
|
|
|
|
2011-05-22 20:13:41 +00:00
|
|
|
FONTS = $(basename $(wildcard fonts/*.c))
|
2011-05-21 17:12:51 +00:00
|
|
|
|
|
|
|
LIBNAME=lcd
|
|
|
|
|
2011-05-11 21:18:46 +00:00
|
|
|
##########################################################################
|
|
|
|
# GNU GCC compiler flags
|
|
|
|
##########################################################################
|
2011-05-21 00:16:03 +00:00
|
|
|
ROOT_PATH?= ..
|
|
|
|
INCLUDE_PATHS = -I$(ROOT_PATH) -I../core -I.
|
2011-05-11 21:18:46 +00:00
|
|
|
|
2011-05-21 00:16:03 +00:00
|
|
|
include $(ROOT_PATH)/Makefile.inc
|
2011-05-11 21:18:46 +00:00
|
|
|
|
2011-05-21 17:12:51 +00:00
|
|
|
FOBJS= $(foreach ft,$(FONTS),$(ft).o)
|
|
|
|
OBJS+= $(FOBJS)
|
|
|
|
LIBFILE=lib$(LIBNAME).a
|
2011-05-11 21:18:46 +00:00
|
|
|
##########################################################################
|
|
|
|
# Compiler settings, parameters and flags
|
|
|
|
##########################################################################
|
|
|
|
|
2011-05-21 17:12:51 +00:00
|
|
|
all: $(LIBFILE) allfonts.h
|
2011-05-11 21:18:46 +00:00
|
|
|
|
2011-05-21 17:12:51 +00:00
|
|
|
$(LIBFILE): $(OBJS)
|
|
|
|
$(AR) rcs $@ $(OBJS)
|
2011-05-11 21:18:46 +00:00
|
|
|
|
|
|
|
%.o : %.c
|
|
|
|
$(CC) $(CFLAGS) -o $@ $<
|
|
|
|
|
2011-05-21 17:12:51 +00:00
|
|
|
$(FOBJS): $(foreach ft,$(FONTS),$(ft).h) fonts.h
|
|
|
|
|
2011-05-11 21:18:46 +00:00
|
|
|
clean:
|
2011-05-22 20:13:41 +00:00
|
|
|
rm -f $(OBJS) $(LIBFILE) fonts/*.o allfonts.h
|
2011-05-11 21:18:46 +00:00
|
|
|
|
|
|
|
render.o: render.c render.h display.h fonts.h
|
|
|
|
|
2011-05-21 17:12:51 +00:00
|
|
|
.PHONY: allfonts.h
|
|
|
|
allfonts.h:
|
2011-05-22 20:13:41 +00:00
|
|
|
(echo "#include <lcd/fonts.h>";for a in $(FONTS) ; do echo "#include <lcd/$$a.h>"; done) > $@
|