diff options
author | Andrew Mahone <andrew.mahone@gmail.com> | 2009-05-07 01:23:13 +0000 |
---|---|---|
committer | Andrew Mahone <andrew.mahone@gmail.com> | 2009-05-07 01:23:13 +0000 |
commit | 5621fd393a4445645b07bb2e89d89d23bb9a6473 (patch) | |
tree | b2b46a056ea1ae599e0a99118ddacdf72a6dac4a /apps/plugins/pictureflow/pictureflow.make | |
parent | 580b1a5c4b305c7cb320415267c5e1b88b053948 (diff) | |
download | rockbox-5621fd393a4445645b07bb2e89d89d23bb9a6473.tar.gz rockbox-5621fd393a4445645b07bb2e89d89d23bb9a6473.zip |
Build pictureflow using overlay on lowmem targets, support JPEG AA in PF on all targets.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20864 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/pictureflow/pictureflow.make')
-rw-r--r-- | apps/plugins/pictureflow/pictureflow.make | 58 |
1 files changed, 58 insertions, 0 deletions
diff --git a/apps/plugins/pictureflow/pictureflow.make b/apps/plugins/pictureflow/pictureflow.make new file mode 100644 index 0000000000..c1fb1f3957 --- /dev/null +++ b/apps/plugins/pictureflow/pictureflow.make | |||
@@ -0,0 +1,58 @@ | |||
1 | # __________ __ ___. | ||
2 | # Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
3 | # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
4 | # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
5 | # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
6 | # \/ \/ \/ \/ \/ | ||
7 | # $Id$ | ||
8 | # | ||
9 | |||
10 | PICTUREFLOW_SRCDIR = $(APPSDIR)/plugins/pictureflow | ||
11 | PICTUREFLOW_OBJDIR = $(BUILDDIR)/apps/plugins/pictureflow | ||
12 | |||
13 | PICTUREFLOW_SRC := $(call preprocess, $(PICTUREFLOW_SRCDIR)/SOURCES) | ||
14 | PICTUREFLOW_OBJ := $(call c2obj, $(PICTUREFLOW_SRC)) | ||
15 | |||
16 | OTHER_SRC += $(PICTUREFLOW_SRC) | ||
17 | |||
18 | ifndef SIMVER | ||
19 | ifneq (,$(strip $(foreach tgt,RECORDER ONDIO,$(findstring $(tgt),$(TARGET))))) | ||
20 | ### lowmem targets | ||
21 | ROCKS += $(PICTUREFLOW_OBJDIR)/pictureflow.ovl | ||
22 | PICTUREFLOW_OUTLDS = $(PICTUREFLOW_OBJDIR)/picutreflow.link | ||
23 | PICTUREFLOW_OVLFLAGS = -T$(PICTUREFLOW_OUTLDS) -Wl,--gc-sections -Wl,-Map,$(basename $@).map | ||
24 | else | ||
25 | ### all other targets | ||
26 | ROCKS += $(PICTUREFLOW_OBJDIR)/pictureflow.rock | ||
27 | endif | ||
28 | else | ||
29 | ### simulator | ||
30 | ROCKS += $(PICTUREFLOW_OBJDIR)/pictureflow.rock | ||
31 | endif | ||
32 | |||
33 | ifeq ($(CPU),sh) | ||
34 | # sh need to retain its' -Os | ||
35 | PICTUREFLOWFLAGS = $(PLUGINFLAGS) | ||
36 | else | ||
37 | PICTUREFLOWFLAGS = $(filter-out -O%,$(PLUGINFLAGS)) -O2 | ||
38 | endif | ||
39 | |||
40 | $(PICTUREFLOW_OBJDIR)/pictureflow.rock: $(PICTUREFLOW_OBJ) | ||
41 | |||
42 | $(PICTUREFLOW_OBJDIR)/pictureflow.refmap: $(PICTUREFLOW_OBJ) | ||
43 | |||
44 | $(PICTUREFLOW_OUTLDS): $(PLUGIN_LDS) $(PICTUREFLOW_OBJDIR)/pictureflow.refmap | ||
45 | $(call PRINTS,PP $(@F))$(call preprocess2file,$<,$@,-DOVERLAY_OFFSET=$(shell \ | ||
46 | $(TOOLSDIR)/ovl_offset.pl $(PICTUREFLOW_OBJDIR)/pictureflow.refmap)) | ||
47 | |||
48 | $(PICTUREFLOW_OBJDIR)/pictureflow.ovl: $(PICTUREFLOW_OBJ) $(PICTUREFLOW_OUTLDS) | ||
49 | $(SILENT)$(CC) $(PLUGINFLAGS) -o $(basename $@).elf \ | ||
50 | $(filter %.o, $^) \ | ||
51 | $(filter %.a, $+) \ | ||
52 | -lgcc $(PICTUREFLOW_OVLFLAGS) | ||
53 | $(call PRINTS,LD $(@F))$(OC) -O binary $(basename $@).elf $@ | ||
54 | |||
55 | # special pattern rule for compiling pictureflow with extra flags | ||
56 | $(PICTUREFLOW_OBJDIR)/%.o: $(PICTUREFLOW_SRCDIR)/%.c $(PLUGINBITMAPLIB) $(PICTUREFLOW_SRCDIR)/pictureflow.make | ||
57 | $(SILENT)mkdir -p $(dir $@) | ||
58 | $(call PRINTS,CC $(subst $(ROOTDIR)/,,$<))$(CC) -I$(dir $<) $(PICTUREFLOWFLAGS) -c $< -o $@ | ||