summaryrefslogtreecommitdiff
path: root/apps/plugins/bitmaps
diff options
context:
space:
mode:
authorBjörn Stenberg <bjorn@haxx.se>2008-11-20 11:27:31 +0000
committerBjörn Stenberg <bjorn@haxx.se>2008-11-20 11:27:31 +0000
commitc6b3d38a156dd624760a8eb1bb374affd43b4f2a (patch)
tree493eba929e2396d86cf4f077709aa09fe172cd35 /apps/plugins/bitmaps
parentf66c30346783a400a029bedcd60ab67c81c34a07 (diff)
downloadrockbox-c6b3d38a156dd624760a8eb1bb374affd43b4f2a.zip
rockbox-c6b3d38a156dd624760a8eb1bb374affd43b4f2a.tar.gz
rockbox-c6b3d38a156dd624760a8eb1bb374affd43b4f2a.tar.bz2
rockbox-c6b3d38a156dd624760a8eb1bb374affd43b4f2a.tar.xz
New makefile solution: A single invocation of 'make' to build the entire tree. Fully controlled dependencies give faster and more correct recompiles.
Many #include lines adjusted to conform to the new standards. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19146 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/bitmaps')
-rw-r--r--apps/plugins/bitmaps/mono/Makefile32
-rw-r--r--apps/plugins/bitmaps/native/Makefile32
-rw-r--r--apps/plugins/bitmaps/native/SOURCES48
-rw-r--r--apps/plugins/bitmaps/native/star_tiles.10x10x2.bmp (renamed from apps/plugins/bitmaps/native/star_tiles.10x10.grey.bmp)bin1678 -> 1678 bytes
-rw-r--r--apps/plugins/bitmaps/native/star_tiles.6x7x1.bmp (renamed from apps/plugins/bitmaps/native/star_tiles.6x7.mono.bmp)bin184 -> 184 bytes
-rw-r--r--apps/plugins/bitmaps/native/star_tiles.8x8x2.bmp (renamed from apps/plugins/bitmaps/native/star_tiles.8x8.grey.bmp)bin390 -> 390 bytes
-rw-r--r--apps/plugins/bitmaps/pluginbitmaps.make59
-rw-r--r--apps/plugins/bitmaps/remote_mono/Makefile32
-rw-r--r--apps/plugins/bitmaps/remote_native/Makefile32
-rw-r--r--apps/plugins/bitmaps/remote_native/SOURCES4
10 files changed, 85 insertions, 154 deletions
diff --git a/apps/plugins/bitmaps/mono/Makefile b/apps/plugins/bitmaps/mono/Makefile
deleted file mode 100644
index 03eb77a..0000000
--- a/apps/plugins/bitmaps/mono/Makefile
+++ /dev/null
@@ -1,32 +0,0 @@
-# __________ __ ___.
-# Open \______ \ ____ ____ | | _\_ |__ _______ ___
-# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
-# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
-# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
-# \/ \/ \/ \/ \/
-# $Id$
-#
-
-INCLUDES= -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(BUILDDIR) \
- -I$(OBJDIR)
-CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES)
-
-# This sets up 'SRC' based on the files mentioned in SOURCES
-include $(TOOLSDIR)/makesrc.inc
-
-SOURCES = $(SRC)
-CSRC := $(SRC:%.bmp=$(OBJDIR)/%.c)
-OBJS := $(CSRC:%.c=%.o)
-DEPFILE = $(OBJDIR)/dep-bitmaps-mono
-
-BMP2RB = $(BMP2RB_MONO)
-OUTPUT = $(BUILDDIR)/libpluginbitmapsmono.a
-BMPINCDIR = $(BUILDDIR)/pluginbitmaps
-
-include $(TOOLSDIR)/makebmp.inc
-
-clean:
- $(call PRINTS,cleaning plugins/bitmaps/mono)rm -f $(CSRC) $(OBJS) $(OUTPUT) $(DEPFILE)
- @rmdir $(OBJDIR)
-
--include $(DEPFILE)
diff --git a/apps/plugins/bitmaps/native/Makefile b/apps/plugins/bitmaps/native/Makefile
deleted file mode 100644
index 071f0d4..0000000
--- a/apps/plugins/bitmaps/native/Makefile
+++ /dev/null
@@ -1,32 +0,0 @@
-# __________ __ ___.
-# Open \______ \ ____ ____ | | _\_ |__ _______ ___
-# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
-# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
-# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
-# \/ \/ \/ \/ \/
-# $Id$
-#
-
-INCLUDES= -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(BUILDDIR) \
- -I$(OBJDIR)
-CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES)
-
-# This sets up 'SRC' based on the files mentioned in SOURCES
-include $(TOOLSDIR)/makesrc.inc
-
-SOURCES = $(SRC)
-CSRC := $(SRC:%.bmp=$(OBJDIR)/%.c)
-OBJS := $(CSRC:%.c=%.o)
-DEPFILE = $(OBJDIR)/dep-bitmaps-native
-
-BMP2RB = $(BMP2RB_NATIVE)
-OUTPUT = $(BUILDDIR)/libpluginbitmapsnative.a
-BMPINCDIR = $(BUILDDIR)/pluginbitmaps
-
-include $(TOOLSDIR)/makebmp.inc
-
-clean:
- $(call PRINTS,cleaning plugins/bitmaps/native)rm -f $(CSRC) $(OBJS) $(OUTPUT) $(DEPFILE)
- @rmdir $(OBJDIR)
-
--include $(DEPFILE)
diff --git a/apps/plugins/bitmaps/native/SOURCES b/apps/plugins/bitmaps/native/SOURCES
index b95fd37..c248bcb 100644
--- a/apps/plugins/bitmaps/native/SOURCES
+++ b/apps/plugins/bitmaps/native/SOURCES
@@ -574,13 +574,13 @@ star_tiles.8x8.bmp
#endif
#elif LCD_DEPTH > 1 /* grey */
#if LCD_WIDTH >= 160 && LCD_HEIGHT >= 98
-star_tiles.10x10.grey.bmp
+star_tiles.10x10x2.bmp
#elif LCD_WIDTH >= 128 && LCD_HEIGHT >= 80
-star_tiles.8x8.grey.bmp
+star_tiles.8x8x2.bmp
#endif
#else /* monochrome */
#if LCD_WIDTH >= 112 && LCD_HEIGHT >= 62
-star_tiles.6x7.mono.bmp
+star_tiles.6x7x1.bmp
#endif
#endif
@@ -669,14 +669,14 @@ matrix_normal.bmp
/* pictureflow */
#if defined(HAVE_LCD_COLOR) && defined(HAVE_ALBUMART) && defined(HAVE_TAGCACHE)
#if (LCD_WIDTH < 200)
- pictureflow_logo.100x18x16.bmp
+pictureflow_logo.100x18x16.bmp
#else
- pictureflow_logo.193x34x16.bmp
+pictureflow_logo.193x34x16.bmp
#endif
#if (LCD_HEIGHT < 100 )
- pictureflow_emptyslide.50x50x16.bmp
+pictureflow_emptyslide.50x50x16.bmp
#else
- pictureflow_emptyslide.100x100x16.bmp
+pictureflow_emptyslide.100x100x16.bmp
#endif
#endif
@@ -689,53 +689,53 @@ matrix_normal.bmp
#if defined HAVE_LCD_COLOR
#if SMALLER_DIMENSION <= 80
- sliding_puzzle.80x80x16.bmp
+sliding_puzzle.80x80x16.bmp
#elif SMALLER_DIMENSION <= 108
- sliding_puzzle.108x108x16.bmp
+sliding_puzzle.108x108x16.bmp
#elif SMALLER_DIMENSION <= 128
- sliding_puzzle.128x128x16.bmp
+sliding_puzzle.128x128x16.bmp
#elif SMALLER_DIMENSION <= 132
- sliding_puzzle.132x132x16.bmp
+sliding_puzzle.132x132x16.bmp
#elif SMALLER_DIMENSION <= 176
- sliding_puzzle.176x176x16.bmp
+sliding_puzzle.176x176x16.bmp
#elif SMALLER_DIMENSION <= 240
- sliding_puzzle.240x240x16.bmp
+sliding_puzzle.240x240x16.bmp
#endif
#elif (LCD_DEPTH > 1)
#if SMALLER_DIMENSION <= 96
- sliding_puzzle.96x96x2.bmp
+sliding_puzzle.96x96x2.bmp
#elif SMALLER_DIMENSION <= 110
- sliding_puzzle.108x108x2.bmp
+sliding_puzzle.108x108x2.bmp
#elif SMALLER_DIMENSION <= 128
- sliding_puzzle.128x128x2.bmp
+sliding_puzzle.128x128x2.bmp
#endif
#else /* mono targets, one size currently */
- sliding_puzzle.80x64x1.bmp
+sliding_puzzle.80x64x1.bmp
#endif
/* Logo */
#if LCD_DEPTH == 16
#if (LCD_WIDTH >= 320)
- rockboxlogo.220x68x16.bmp
+rockboxlogo.220x68x16.bmp
#elif (LCD_WIDTH > 160)
- rockboxlogo.128x40x16.bmp
+rockboxlogo.128x40x16.bmp
#else
- rockboxlogo.90x28x16.bmp
+rockboxlogo.90x28x16.bmp
#endif
#elif LCD_DEPTH == 2
#if (LCD_WIDTH > 138)
- rockboxlogo.138x46x2.bmp
+rockboxlogo.138x46x2.bmp
#else
- rockboxlogo.91x32x2.bmp
+rockboxlogo.91x32x2.bmp
#endif
#elif LCD_DEPTH == 1
#if (LCD_WIDTH > 112)
/* Such a screen isn't currently in any target */
- rockboxlogo.112x30x1.bmp
+rockboxlogo.112x30x1.bmp
#else
- rockboxlogo.91x32x1.bmp
+rockboxlogo.91x32x1.bmp
#endif
#endif
diff --git a/apps/plugins/bitmaps/native/star_tiles.10x10.grey.bmp b/apps/plugins/bitmaps/native/star_tiles.10x10x2.bmp
index 54e14bb..54e14bb 100644
--- a/apps/plugins/bitmaps/native/star_tiles.10x10.grey.bmp
+++ b/apps/plugins/bitmaps/native/star_tiles.10x10x2.bmp
Binary files differ
diff --git a/apps/plugins/bitmaps/native/star_tiles.6x7.mono.bmp b/apps/plugins/bitmaps/native/star_tiles.6x7x1.bmp
index ebc59b9..ebc59b9 100644
--- a/apps/plugins/bitmaps/native/star_tiles.6x7.mono.bmp
+++ b/apps/plugins/bitmaps/native/star_tiles.6x7x1.bmp
Binary files differ
diff --git a/apps/plugins/bitmaps/native/star_tiles.8x8.grey.bmp b/apps/plugins/bitmaps/native/star_tiles.8x8x2.bmp
index 6f810ce..6f810ce 100644
--- a/apps/plugins/bitmaps/native/star_tiles.8x8.grey.bmp
+++ b/apps/plugins/bitmaps/native/star_tiles.8x8x2.bmp
Binary files differ
diff --git a/apps/plugins/bitmaps/pluginbitmaps.make b/apps/plugins/bitmaps/pluginbitmaps.make
new file mode 100644
index 0000000..7dbcc0b
--- /dev/null
+++ b/apps/plugins/bitmaps/pluginbitmaps.make
@@ -0,0 +1,59 @@
+# __________ __ ___.
+# Open \______ \ ____ ____ | | _\_ |__ _______ ___
+# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
+# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
+# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
+# \/ \/ \/ \/ \/
+# $Id: Makefile 19082 2008-11-10 23:54:24Z zagor $
+#
+
+PBMPINCDIR = $(BUILDDIR)/pluginbitmaps
+
+PFLAGS += -I$(PBMPINCDIR)
+
+ifneq ($(strip $(BMP2RB_MONO)),)
+PBMP = $(call preprocess, $(APPSDIR)/plugins/bitmaps/mono/SOURCES)
+endif
+ifneq ($(strip $(BMP2RB_NATIVE)),)
+PBMP += $(call preprocess, $(APPSDIR)/plugins/bitmaps/native/SOURCES)
+endif
+ifneq ($(strip $(BMP2RB_REMOTEMONO)),)
+PBMP += $(call preprocess, $(APPSDIR)/plugins/bitmaps/remote_mono/SOURCES)
+endif
+ifneq ($(strip $(BMP2RB_REMOTENATIVE)),)
+PBMP += $(call preprocess, $(APPSDIR)/plugins/bitmaps/remote_native/SOURCES)
+endif
+
+ifdef PBMP # does player use bitmaps?
+
+PLUGIN_BITMAPS := $(PBMP:$(ROOTDIR)/%.bmp=$(BUILDDIR)/%.o)
+
+PLUGINBITMAPLIB := $(BUILDDIR)/apps/plugins/bitmaps/libpluginbitmaps.a
+PLUGINBITMAPDIR := $(dir $(PLUGINBITMAPLIB))
+
+PBMPHFILES := $(subst $(ROOTDIR),$(BUILDDIR),$(PBMP))
+PBMPHFILES := $(shell echo $(PBMPHFILES) | sed -e 's/\.[0-9x]\+\.bmp/.h/g' -e 's/\.bmp/.h/g' -e 's/apps\/plugins\/bitmaps\/\(mono\|native\|remote_mono\|remote_native\)/pluginbitmaps/g')
+
+$(PBMPHFILES): $(PLUGIN_BITMAPS)
+
+$(PLUGINBITMAPLIB): $(PLUGIN_BITMAPS)
+ $(call PRINTS,AR $(@F))$(AR) rs $@ $+ >/dev/null 2>&1
+
+# pattern rules to create .c files from .bmp, one for each subdir:
+$(BUILDDIR)/apps/plugins/bitmaps/mono/%.c: $(ROOTDIR)/apps/plugins/bitmaps/mono/%.bmp $(TOOLSDIR)/bmp2rb
+ $(SILENT)mkdir -p $(dir $@) $(PBMPINCDIR)
+ $(call PRINTS,BMP2RB $(<F))$(BMP2RB_MONO) -h $(PBMPINCDIR) $< > $@
+
+$(BUILDDIR)/apps/plugins/bitmaps/native/%.c: $(ROOTDIR)/apps/plugins/bitmaps/native/%.bmp $(TOOLSDIR)/bmp2rb
+ $(SILENT)mkdir -p $(dir $@) $(PBMPINCDIR)
+ $(call PRINTS,BMP2RB $(<F))$(BMP2RB_NATIVE) -h $(PBMPINCDIR) $< > $@
+
+$(BUILDDIR)/apps/plugins/bitmaps/remote_mono/%.c: $(ROOTDIR)/apps/plugins/bitmaps/remote_mono/%.bmp $(TOOLSDIR)/bmp2rb
+ $(SILENT)mkdir -p $(dir $@) $(PBMPINCDIR)
+ $(call PRINTS,BMP2RB $(<F))$(BMP2RB_REMOTEMONO) -h $(PBMPINCDIR) $< > $@
+
+$(BUILDDIR)/apps/plugins/bitmaps/remote_native/%.c: $(ROOTDIR)/apps/plugins/bitmaps/remote_native/%.bmp $(TOOLSDIR)/bmp2rb
+ $(SILENT)mkdir -p $(dir $@) $(PBMPINCDIR)
+ $(call PRINTS,BMP2RB $(<F))$(BMP2RB_REMOTENATIVE) -h $(PBMPINCDIR) $< > $@
+
+endif
diff --git a/apps/plugins/bitmaps/remote_mono/Makefile b/apps/plugins/bitmaps/remote_mono/Makefile
deleted file mode 100644
index d3858fa..0000000
--- a/apps/plugins/bitmaps/remote_mono/Makefile
+++ /dev/null
@@ -1,32 +0,0 @@
-# __________ __ ___.
-# Open \______ \ ____ ____ | | _\_ |__ _______ ___
-# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
-# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
-# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
-# \/ \/ \/ \/ \/
-# $Id$
-#
-
-INCLUDES= -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(BUILDDIR) \
- -I$(OBJDIR)
-CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES)
-
-# This sets up 'SRC' based on the files mentioned in SOURCES
-include $(TOOLSDIR)/makesrc.inc
-
-SOURCES = $(SRC)
-CSRC := $(SRC:%.bmp=$(OBJDIR)/%.c)
-OBJS := $(CSRC:%.c=%.o)
-DEPFILE = $(OBJDIR)/dep-bitmaps-remotemono
-
-BMP2RB = $(BMP2RB_REMOTEMONO)
-OUTPUT = $(BUILDDIR)/libpluginbitmapsremotemono.a
-BMPINCDIR = $(BUILDDIR)/pluginbitmaps
-
-include $(TOOLSDIR)/makebmp.inc
-
-clean:
- $(call PRINTS,cleaning plugins/bitmaps/remotemono)rm -f $(CSRC) $(OBJS) $(OUTPUT) $(DEPFILE)
- @rmdir $(OBJDIR)
-
--include $(DEPFILE)
diff --git a/apps/plugins/bitmaps/remote_native/Makefile b/apps/plugins/bitmaps/remote_native/Makefile
deleted file mode 100644
index 3802e75..0000000
--- a/apps/plugins/bitmaps/remote_native/Makefile
+++ /dev/null
@@ -1,32 +0,0 @@
-# __________ __ ___.
-# Open \______ \ ____ ____ | | _\_ |__ _______ ___
-# Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ /
-# Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < <
-# Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \
-# \/ \/ \/ \/ \/
-# $Id$
-#
-
-INCLUDES= -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I. -I$(BUILDDIR) \
- -I$(OBJDIR)
-CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES)
-
-# This sets up 'SRC' based on the files mentioned in SOURCES
-include $(TOOLSDIR)/makesrc.inc
-
-SOURCES = $(SRC)
-CSRC := $(SRC:%.bmp=$(OBJDIR)/%.c)
-OBJS := $(CSRC:%.c=%.o)
-DEPFILE = $(OBJDIR)/dep-bitmaps-remotenative
-
-BMP2RB = $(BMP2RB_REMOTENATIVE)
-OUTPUT = $(BUILDDIR)/libpluginbitmapsremotenative.a
-BMPINCDIR = $(BUILDDIR)/pluginbitmaps
-
-include $(TOOLSDIR)/makebmp.inc
-
-clean:
- $(call PRINTS,cleaning plugins/bitmaps/remote_native)rm -f $(CSRC) $(OBJS) $(OUTPUT) $(DEPFILE)
- @rmdir $(OBJDIR)
-
--include $(DEPFILE)
diff --git a/apps/plugins/bitmaps/remote_native/SOURCES b/apps/plugins/bitmaps/remote_native/SOURCES
index 3633f23..2bc3d59 100644
--- a/apps/plugins/bitmaps/remote_native/SOURCES
+++ b/apps/plugins/bitmaps/remote_native/SOURCES
@@ -18,7 +18,7 @@ clock_smallsegments_remote.112x64x1.bmp
/* Logo */
#if (LCD_REMOTE_DEPTH == 1)
- remote_rockboxlogo.91x32x1.bmp
+remote_rockboxlogo.91x32x1.bmp
#elif (LCD_REMOTE_DEPTH == 2)
- remote_rockboxlogo.91x32x2.bmp
+remote_rockboxlogo.91x32x2.bmp
#endif