2008-11-20 11:27:31 +00:00
|
|
|
# __________ __ ___.
|
|
|
|
# Open \______ \ ____ ____ | | _\_ |__ _______ ___
|
|
|
|
# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
|
|
|
|
# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
|
|
|
|
# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
|
|
|
|
# \/ \/ \/ \/ \/
|
2008-11-25 19:54:23 +00:00
|
|
|
# $Id$
|
2008-11-20 11:27:31 +00:00
|
|
|
#
|
|
|
|
|
2013-12-04 16:06:17 +00:00
|
|
|
INCLUDES += -I$(FIRMDIR) -I$(FIRMDIR)/export -I$(FIRMDIR)/drivers \
|
|
|
|
-I$(FIRMDIR)/include -I$(FIRMDIR)/kernel/include
|
2010-07-10 13:49:49 +00:00
|
|
|
ifndef APP_TYPE
|
2010-05-14 12:37:05 +00:00
|
|
|
INCLUDES += -I$(FIRMDIR)/libc/include
|
|
|
|
endif
|
2008-11-20 11:27:31 +00:00
|
|
|
|
2012-01-07 18:49:02 +00:00
|
|
|
include $(FIRMDIR)/asm/asm.make
|
|
|
|
|
2008-11-20 11:27:31 +00:00
|
|
|
FIRMLIB_SRC += $(call preprocess, $(FIRMDIR)/SOURCES)
|
|
|
|
FIRMLIB_OBJ := $(call c2obj, $(FIRMLIB_SRC))
|
2009-01-02 12:47:11 +00:00
|
|
|
ifeq (,$(findstring -DARCHOS_PLAYER,$(TARGET)))
|
|
|
|
FIRMLIB_OBJ += $(BUILDDIR)/sysfont.o
|
|
|
|
endif
|
2008-11-20 11:27:31 +00:00
|
|
|
OTHER_SRC += $(FIRMLIB_SRC)
|
|
|
|
|
|
|
|
FIRMLIB = $(BUILDDIR)/firmware/libfirmware.a
|
|
|
|
|
|
|
|
SYSFONT = $(ROOTDIR)/fonts/08-Schumacher-Clean.bdf
|
|
|
|
|
2010-05-27 09:41:46 +00:00
|
|
|
CLEANOBJS += $(BUILDDIR)/sysfont.* $(BUILDDIR)/version.*
|
2008-11-20 11:27:31 +00:00
|
|
|
|
|
|
|
# Limits for the built-in sysfont: ASCII for bootloaders, ISO8859-1 for normal builds
|
|
|
|
ifneq (,$(findstring -DBOOTLOADER,$(EXTRA_DEFINES)))
|
|
|
|
MAXCHAR = 127
|
|
|
|
else
|
|
|
|
MAXCHAR = 255
|
|
|
|
endif
|
|
|
|
|
|
|
|
$(FIRMLIB): $(FIRMLIB_OBJ)
|
2008-11-20 16:49:55 +00:00
|
|
|
$(SILENT)$(shell rm -f $@)
|
2009-03-01 09:04:15 +00:00
|
|
|
$(call PRINTS,AR $(@F))$(AR) rcs $@ $^ >/dev/null
|
2008-11-20 11:27:31 +00:00
|
|
|
|
2014-01-26 14:02:11 +00:00
|
|
|
$(BUILDDIR)/sysfont.h: $(SYSFONT) $(TOOLS) $(BUILDDIR)/firmware/common/config.o
|
2008-11-20 11:27:31 +00:00
|
|
|
$(call PRINTS,CONVBDF $(subst $(ROOTDIR)/,,$<))$(TOOLSDIR)/convbdf -l $(MAXCHAR) -h -o $@ $<
|
|
|
|
|
|
|
|
$(BUILDDIR)/sysfont.o: $(SYSFONT) $(BUILDDIR)/sysfont.h
|
|
|
|
$(call PRINTS,CONVBDF $(subst $(ROOTDIR)/,,$<))$(TOOLSDIR)/convbdf -l $(MAXCHAR) -c -o $(BUILDDIR)/sysfont.c $<
|
|
|
|
$(call PRINTS,CC $(subst $(ROOTDIR)/,,$(BUILDDIR)/sysfont.c))$(CC) $(CFLAGS) -c $(BUILDDIR)/sysfont.c -o $@
|
|
|
|
|
2010-06-21 00:02:36 +00:00
|
|
|
SVNVERSION:=$(shell $(TOOLSDIR)/version.sh $(ROOTDIR))
|
2010-06-20 23:54:21 +00:00
|
|
|
OLDSVNVERSION:=$(shell grep 'RBVERSION' $(BUILDDIR)/version.h 2>/dev/null|cut -d '"' -f 2 || echo "NOREVISION")
|
|
|
|
|
|
|
|
ifneq ($(SVNVERSION),$(OLDSVNVERSION))
|
|
|
|
.PHONY: $(BUILDDIR)/version.h
|
|
|
|
endif
|
|
|
|
|
2010-05-28 04:07:57 +00:00
|
|
|
$(BUILDDIR)/version.h:
|
2010-06-23 00:12:31 +00:00
|
|
|
$(call PRINTS,GEN $(@F))$(TOOLSDIR)/genversion.sh $(BUILDDIR) $(TOOLSDIR)/version.sh $(ROOTDIR)
|