diff options
author | mrwastl <mrwastl@users.sourceforge.net> | 2011-05-08 00:06:31 +0200 |
---|---|---|
committer | mrwastl <mrwastl@users.sourceforge.net> | 2011-05-08 00:06:31 +0200 |
commit | 3cb5c3e2d38f284738af6af736df3c4addd85575 (patch) | |
tree | 4d3a826ee7b1b05a73db61a55daa7127e6b1bd10 /glcdgraphics/Makefile | |
parent | 00e8503d301acc98c012b4ebd5467ebcd99915d0 (diff) | |
download | graphlcd-base-3cb5c3e2d38f284738af6af736df3c4addd85575.tar.gz graphlcd-base-3cb5c3e2d38f284738af6af736df3c4addd85575.tar.bz2 |
add basic reading support for image formats supported by ImageMagick (optional, not enabled by default)
Diffstat (limited to 'glcdgraphics/Makefile')
-rw-r--r-- | glcdgraphics/Makefile | 21 |
1 files changed, 19 insertions, 2 deletions
diff --git a/glcdgraphics/Makefile b/glcdgraphics/Makefile index 399b3ad..d301804 100644 --- a/glcdgraphics/Makefile +++ b/glcdgraphics/Makefile @@ -4,6 +4,11 @@ -include ../Make.config +# External image lib to use: imagemagick, graphicsmagick, or none +# taken from text2skin +IMAGELIB = + + CXXFLAGS += -fPIC VERMAJOR = 2 @@ -14,9 +19,9 @@ BASENAME = libglcdgraphics.so LIBNAME = $(BASENAME).$(VERMAJOR).$(VERMINOR).$(VERMICRO) -OBJS = bitmap.o common.o font.o glcd.o image.o imagefile.o pbm.o +OBJS = bitmap.o common.o font.o glcd.o image.o imagefile.o pbm.o extformats.o -HEADERS = bitmap.h font.h glcd.h image.h imagefile.h pbm.h +HEADERS = bitmap.h font.h glcd.h image.h imagefile.h pbm.h extformats.h ### Implicit rules: @@ -43,6 +48,18 @@ ifdef HAVE_FREETYPE2 DEFINES += -DHAVE_FREETYPE2 endif### Targets: + +ifeq ($(IMAGELIB), imagemagick) + DEFINES += -DHAVE_IMAGEMAGICK + INCLUDES += $(shell pkg-config --cflags ImageMagick++) + LIBS += $(shell pkg-config --libs ImageMagick++) +else ifeq ($(IMAGELIB), graphicsmagick) + DEFINES += -DHAVE_IMAGEMAGICK # yep, really HAVE_IMAGEMAGICK here + INCLUDES += $(shell pkg-config --cflags GraphicsMagick++) + LIBS += $(shell pkg-config --libs GraphicsMagick++) +endif + + all: $(LIBNAME) $(LIBNAME): $(OBJS) |