diff options
author | mrwastl <mrwastl@users.sourceforge.net> | 2013-03-17 10:09:34 +0100 |
---|---|---|
committer | mrwastl <mrwastl@users.sourceforge.net> | 2013-03-17 10:09:34 +0100 |
commit | fde257735d153922d90a7378d4d577d5001772d0 (patch) | |
tree | 412c430c5912c8b45ebbe67134eb8b4f47e31fa2 | |
parent | 1917182efa2d47eb107d97041abea2385ffd33ee (diff) | |
parent | 281feef328f8e3772f7a0dde0a90c3a5260c334d (diff) | |
download | graphlcd-base-fde257735d153922d90a7378d4d577d5001772d0.tar.gz graphlcd-base-fde257735d153922d90a7378d4d577d5001772d0.tar.bz2 |
Merge branch 'touchcol' of ssh://projects.vdr-developer.org/graphlcd-base into touchcol
-rw-r--r-- | Make.config | 12 | ||||
-rw-r--r-- | README | 4 | ||||
-rw-r--r-- | glcddrivers/ax206dpf.c | 2 | ||||
-rw-r--r-- | glcddrivers/picoLCD_256x64.h | 2 | ||||
-rw-r--r-- | glcdgraphics/bitmap.c | 30 | ||||
-rw-r--r-- | glcdgraphics/font.c | 4 | ||||
-rw-r--r-- | glcdgraphics/glcd.c | 2 | ||||
-rw-r--r-- | tools/convpic/Makefile | 2 | ||||
-rw-r--r-- | tools/crtfont/Makefile | 2 | ||||
-rw-r--r-- | tools/genfont/Makefile | 2 | ||||
-rw-r--r-- | tools/lcdtestpattern/Makefile | 2 | ||||
-rw-r--r-- | tools/showpic/Makefile | 2 | ||||
-rw-r--r-- | tools/showtext/Makefile | 2 |
13 files changed, 41 insertions, 27 deletions
diff --git a/Make.config b/Make.config index f6a668f..4ea4af6 100644 --- a/Make.config +++ b/Make.config @@ -50,6 +50,15 @@ MANDIR = $(DESTDIR)/man #INCLUDES += -I DEFINES += -D_GNU_SOURCE +# define HAVE_DEBUG when invoking "make" if you want to use debugging +ifdef HAVE_DEBUG +DEFINES += -DHAVE_DEBUG +endif + + +# +# +# Build & install configuration # comment this variable out if you don't want to use FreeType2 font rendering HAVE_FREETYPE2=1 @@ -57,6 +66,9 @@ HAVE_FREETYPE2=1 # comment this variable out if you don't want to use fontconfig font names HAVE_FONTCONFIG=1 +# comment this if you do not want to have the binaries pre-stripped on 'make install' +PRESTRIP = -s + # uncomment one of the following two lines if you want either GraphicsMagick/ImageMagick support #HAVE_IMAGEMAGICK=1 #HAVE_GRAPHICSMAGICK=1 @@ -66,8 +66,8 @@ Installation and Configuration: tar xzf graphlcd-base-0.1.2.tgz -2. Configure if you want FreeType2 support by commenting/uncommenting - HAVE_FREETYPE2 in Make.config. +2. Configure the package to your needs, by following the comments in the + "Build & install configuration" section in Make.config. 3. Compile the libraries and tools. diff --git a/glcddrivers/ax206dpf.c b/glcddrivers/ax206dpf.c index 7c9935a..f715585 100644 --- a/glcddrivers/ax206dpf.c +++ b/glcddrivers/ax206dpf.c @@ -878,7 +878,7 @@ static struct usb_device *find_dev(int index) else enumeration++; } -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%04x %04x\n", d->descriptor.idVendor, d->descriptor.idProduct); diff --git a/glcddrivers/picoLCD_256x64.h b/glcddrivers/picoLCD_256x64.h index 223d748..4f8ce75 100644 --- a/glcddrivers/picoLCD_256x64.h +++ b/glcddrivers/picoLCD_256x64.h @@ -37,7 +37,7 @@ #define SCREEN_H 64 #define SCREEN_W 256 -#if 0 +#ifdef HAVE_DEBUG #define DEBUG(x) fprintf(stderr,"picoLCD_256x64: %s(): " #x "\n", __FUNCTION__); #define DEBUG1(x,...) fprintf(stderr,"picoLCD_256x64: %s(): " #x "\n", __FUNCTION__, __VA_ARGS__); #else diff --git a/glcdgraphics/bitmap.c b/glcdgraphics/bitmap.c index adfe551..227e140 100644 --- a/glcdgraphics/bitmap.c +++ b/glcdgraphics/bitmap.c @@ -93,7 +93,7 @@ cBitmap::cBitmap(int width, int height, uint32_t * data) ismonochrome(false), processAlpha(true) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) cBitmap Size %03d * %03d\n", __FILE__, __FUNCTION__, __LINE__, width, height); #endif if (width > 0 && height > 0) { @@ -113,7 +113,7 @@ cBitmap::cBitmap(int width, int height, uint32_t initcol) ismonochrome(false), processAlpha(true) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) cBitmap Size %03d * %03d\n", __FILE__, __FUNCTION__, __LINE__, width, height); #endif @@ -146,7 +146,7 @@ cBitmap::~cBitmap() void cBitmap::Clear(uint32_t color) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, width, height, color); #endif //uint32_t col = initcol; //(initcol == cColor::Transparent) ? backgroundColor : initcol; @@ -262,7 +262,7 @@ void cBitmap::DrawLine(int x1, int y1, int x2, int y2, uint32_t color) void cBitmap::DrawHLine(int x1, int y, int x2, uint32_t color) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d -> %03d, %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, x1, x2, y, color); #endif color = cColor::AlignAlpha(color); @@ -276,7 +276,7 @@ void cBitmap::DrawHLine(int x1, int y, int x2, uint32_t color) void cBitmap::DrawVLine(int x, int y1, int y2, uint32_t color) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d, %03d -> %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, x, y1, y2, color); #endif color = cColor::AlignAlpha(color); @@ -290,7 +290,7 @@ void cBitmap::DrawVLine(int x, int y1, int y2, uint32_t color) void cBitmap::DrawRectangle(int x1, int y1, int x2, int y2, uint32_t color, bool filled) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d -> %03d * %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, x1, y1, x2, y2, color); #endif int y; @@ -318,7 +318,7 @@ void cBitmap::DrawRectangle(int x1, int y1, int x2, int y2, uint32_t color, bool void cBitmap::DrawRoundRectangle(int x1, int y1, int x2, int y2, uint32_t color, bool filled, int type) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d -> %03d * %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, x1, y1, x2, y2, color); #endif color = cColor::AlignAlpha(color); @@ -376,7 +376,7 @@ void cBitmap::DrawRoundRectangle(int x1, int y1, int x2, int y2, uint32_t color, void cBitmap::DrawEllipse(int x1, int y1, int x2, int y2, uint32_t color, bool filled, int quadrants) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d -> %03d * %03d (color %08x)\n", __FILE__, __FUNCTION__, __LINE__, x1, y1, x2, y2, color); #endif color = cColor::AlignAlpha(color); @@ -522,7 +522,7 @@ void cBitmap::DrawEllipse(int x1, int y1, int x2, int y2, uint32_t color, bool f void cBitmap::DrawSlope(int x1, int y1, int x2, int y2, uint32_t color, int type) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d -> %03d * %03d\n", __FILE__, __FUNCTION__, __LINE__, x1, y1, x2, y2); #endif color = cColor::AlignAlpha(color); @@ -562,7 +562,7 @@ void cBitmap::DrawSlope(int x1, int y1, int x2, int y2, uint32_t color, int type void cBitmap::DrawBitmap(int x, int y, const cBitmap & bitmap, uint32_t color, uint32_t bgcolor, int opacity) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) '%03d' x '%03d' \n", __FILE__, __FUNCTION__, __LINE__, x, y); #endif color = cColor::AlignAlpha(color); @@ -602,7 +602,7 @@ void cBitmap::DrawBitmap(int x, int y, const cBitmap & bitmap, uint32_t color, u int cBitmap::DrawText(int x, int y, int xmax, const std::string & text, const cFont * font, uint32_t color, uint32_t bgcolor, bool proportional, int skipPixels) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) text '%s', color '%08x'/'%08x'\n", __FILE__, __FUNCTION__, __LINE__, text.c_str(), color, bgcolor); #endif int xt; @@ -704,7 +704,7 @@ int cBitmap::DrawText(int x, int y, int xmax, const std::string & text, const cF int cBitmap::DrawCharacter(int x, int y, int xmax, uint32_t c, const cFont * font, uint32_t color, uint32_t bgcolor, int skipPixels) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d char '%c' color '%08x' bgcolor '%08x'\n", __FILE__, __FUNCTION__, __LINE__, x, y, c, color, bgcolor); #endif const cBitmap * charBitmap; @@ -763,7 +763,7 @@ uint32_t cBitmap::GetPixel(int x, int y) const cBitmap * cBitmap::SubBitmap(int x1, int y1, int x2, int y2) const { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) %03d * %03d / %03d * %03d\n", __FILE__, __FUNCTION__, __LINE__, x1, y1, x2, y2); #endif int w, h; @@ -857,7 +857,7 @@ const cBitmap* cBitmap::ConvertFrom1BPP(const unsigned char* monobmp, int w, int #if 0 bool cBitmap::LoadPBM(const std::string & fileName) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d)\n", __FILE__, __FUNCTION__, __LINE__); #endif FILE * pbmFile; @@ -948,7 +948,7 @@ bool cBitmap::LoadPBM(const std::string & fileName) void cBitmap::SavePBM(const std::string & fileName) { -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d)\n", __FILE__, __FUNCTION__, __LINE__); #endif int i; diff --git a/glcdgraphics/font.c b/glcdgraphics/font.c index 24a44a0..7e82cee 100644 --- a/glcdgraphics/font.c +++ b/glcdgraphics/font.c @@ -29,6 +29,8 @@ #include <ft2build.h> #include FT_FREETYPE_H #include <iconv.h> +#else +#include <string.h> #endif namespace GLCD @@ -168,7 +170,7 @@ bool cFont::LoadFNT(const std::string & fileName, const std::string & encoding) character = chdr[0] | (chdr[1] << 8); charWidth = chdr[2] | (chdr[3] << 8); fread(buffer, fontHeight * ((charWidth + 7) / 8), 1, fontFile); -#ifdef DEBUG +#ifdef HAVE_DEBUG printf ("fontHeight %0d - charWidth %0d - character %0d - bytes %0d\n", fontHeight, charWidth, character,fontHeight * ((charWidth + 7) / 8)); #endif diff --git a/glcdgraphics/glcd.c b/glcdgraphics/glcd.c index 30449b9..3b2c3f3 100644 --- a/glcdgraphics/glcd.c +++ b/glcdgraphics/glcd.c @@ -188,7 +188,7 @@ bool cGLCDFile::Load(cImage & image, const string & fileName) } } } -#ifdef DEBUG +#ifdef HAVE_DEBUG printf("%s:%s(%d) - filename: '%s', count %d\n", __FILE__, __FUNCTION__, __LINE__, fileName.c_str(), n); #endif cBitmap * b = new cBitmap(width, height, bmpdata); diff --git a/tools/convpic/Makefile b/tools/convpic/Makefile index 93cdd71..771bc3e 100644 --- a/tools/convpic/Makefile +++ b/tools/convpic/Makefile @@ -36,7 +36,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) diff --git a/tools/crtfont/Makefile b/tools/crtfont/Makefile index 815ea2e..a9741c0 100644 --- a/tools/crtfont/Makefile +++ b/tools/crtfont/Makefile @@ -35,7 +35,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) diff --git a/tools/genfont/Makefile b/tools/genfont/Makefile index 20cab12..0bd2279 100644 --- a/tools/genfont/Makefile +++ b/tools/genfont/Makefile @@ -38,7 +38,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) diff --git a/tools/lcdtestpattern/Makefile b/tools/lcdtestpattern/Makefile index 9b7b905..29af7fc 100644 --- a/tools/lcdtestpattern/Makefile +++ b/tools/lcdtestpattern/Makefile @@ -36,7 +36,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) diff --git a/tools/showpic/Makefile b/tools/showpic/Makefile index 93c039a..6bb2bc2 100644 --- a/tools/showpic/Makefile +++ b/tools/showpic/Makefile @@ -36,7 +36,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) diff --git a/tools/showtext/Makefile b/tools/showtext/Makefile index 542482a..139d2e8 100644 --- a/tools/showtext/Makefile +++ b/tools/showtext/Makefile @@ -36,7 +36,7 @@ $(PRGNAME): $(OBJS) install: $(PRGNAME) install -d $(BINDIR) - install -m 755 -o root -g root -s $(PRGNAME) $(BINDIR) + install -m 755 -o root -g root $(PRESTRIP) $(PRGNAME) $(BINDIR) uninstall: rm -f $(BINDIR)/$(PRGNAME) |