New makefile solution: A single invocation of 'make' to build the entire tree. Fully...
[kugel-rb.git] / apps / plugins / reversi / reversi.make
blobbe7369423ee9e529eb6192300069a0b19dd30151
1 # __________ __ ___.
2 # Open \______ \ ____ ____ | | _\_ |__ _______ ___
3 # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
4 # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
5 # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
6 # \/ \/ \/ \/ \/
7 # $Id: Makefile 19082 2008-11-10 23:54:24Z zagor $
10 REVERSISRCDIR := $(APPSDIR)/plugins/reversi
11 REVERSIBUILDDIR := $(BUILDDIR)/apps/plugins/reversi
13 ROCKS += $(REVERSIBUILDDIR)/reversi.rock
15 REVERSI_SRC := $(call preprocess, $(REVERSISRCDIR)/SOURCES)
16 REVERSI_OBJ := $(call c2obj, $(REVERSI_SRC))
18 # add source files to OTHER_SRC to get automatic dependencies
19 OTHER_SRC += $(REVERSI_SRC)
21 $(REVERSIBUILDDIR)/reversi.rock: $(REVERSI_OBJ)
22 # for some reason, this doesn't match the implicit rule in plugins.make,
23 # so we have to duplicate the link command here
24 $(SILENT)$(CC) $(PLUGINFLAGS) -o $*.elf \
25 $(filter %.o, $^) \
26 $(filter %.a, $^) \
27 -lgcc $(PLUGINLDFLAGS)
28 $(call PRINTS,LD $(@F))$(OC) -O binary $*.elf $@