Mercurial > MadButterfly
changeset 662:689e15edbf72
Merge the head from FourDollars
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Sun, 01 Aug 2010 20:20:33 +0800 |
parents | 90c7726bc953 (current diff) 21f944e79b19 (diff) |
children | 974d98233eab |
files | |
diffstat | 7 files changed, 29 insertions(+), 24 deletions(-) [+] |
line wrap: on
line diff
--- a/build-mipsel.sh Sun Aug 01 20:18:59 2010 +0800 +++ b/build-mipsel.sh Sun Aug 01 20:20:33 2010 +0800 @@ -1,5 +1,5 @@ #!/bin/sh autoreconf -ifs -./configure --host mipsel-linux --build i686-pc-linux-gnu --prefix ${TANGO} --disable-sh_text --disable-X_supp +./configure --host mipsel-linux --build i686-pc-linux-gnu --prefix ${TANGO} --disable-sh_text --with-backend=dfb make && make install
--- a/configure.ac Sun Aug 01 20:18:59 2010 +0800 +++ b/configure.ac Sun Aug 01 20:20:33 2010 +0800 @@ -64,13 +64,14 @@ AC_DEFINE([SH_STEXT]) [fi] -AC_ARG_ENABLE([X_supp], - [AS_HELP_STRING([--disable-X_supp],[Turn off X backend])], - [case "${enableval}" in - (yes) X_supp=true ;; - (no) X_supp=false ;; - (*) AC_MSG_ERROR([bad value ${enableval} for --disable-X_supp]) ;; - esac],[X_supp=true]) +AC_ARG_WITH([backend], + [AS_HELP_STRING([--with-backend=FOO],[Use FOO as display backend (default is 'X')])], + [case "${withval}" in + ('X') backend='X' ;; + ('dfb') backend='dfb' ;; + ('no') backend='none' ;; + (*) AC_MSG_ERROR([bad value ${withval} for --with-backend]) ;; + esac],[backend='X']) AC_ARG_ENABLE([skia], [AS_HELP_STRING([--enable-skia],[Turn on Skia instead of Cairo])], @@ -114,12 +115,18 @@ AC_DEFINE([SH_TEXT]) [fi] -# Define AM and AC variable for X_supp +# Define AM and AC variable for display backend + +AM_CONDITIONAL([X_BACKEND], [test x$backend = x'X' -a x$cairo = xtrue]) -AM_CONDITIONAL([X_SUPP], [test x$X_supp = xtrue -a x$cairo = xtrue]) +[if [ x"${backend}" = x'X' -a x"${cairo}" = xtrue ]; then] + AC_DEFINE([X_BACKEND]) +[fi] -[if [ x"${X_supp}" = xtrue -a x"${cairo}" = xtrue ]; then] - AC_DEFINE([X_SUPP]) +AM_CONDITIONAL([DFB_BACKEND], [test x$backend = x'dfb' -a x$cairo = xtrue]) + +[if [ x"${backend}" = x'dfb' -a x"${cairo}" = xtrue ]; then] + AC_DEFINE([DFB_BACKEND]) [fi] # Checks for libraries. @@ -153,6 +160,7 @@ AH_TEMPLATE([SH_STEXT],[Enable sh_stext object]) AH_TEMPLATE([SKIA_GRAPH_ENGINE], [Enable Skia Graphic Engine]) AH_TEMPLATE([CAIRO_GRAPH_ENGINE], [Enable Cairo Graphic Engine]) -AH_TEMPLATE([X_SUPP], [Enable X backend]) +AH_TEMPLATE([X_BACKEND], [Enable X backend]) +AH_TEMPLATE([DFB_BACKEND], [Enable DirectFB backend]) AC_OUTPUT
--- a/examples/Makefile.am Sun Aug 01 20:18:59 2010 +0800 +++ b/examples/Makefile.am Sun Aug 01 20:20:33 2010 +0800 @@ -1,3 +1,3 @@ -if X_SUPP +if X_BACKEND SUBDIRS = calculator svg2code_ex tank dynamic drag menu endif
--- a/include/mb.h Sun Aug 01 20:18:59 2010 +0800 +++ b/include/mb.h Sun Aug 01 20:20:33 2010 +0800 @@ -5,7 +5,7 @@ #include "mb_types.h" #include "mb_redraw_man.h" -#ifdef X_SUPP +#ifdef X_BACKEND #include "mb_X_supp.h" #endif #include "mb_animate.h"
--- a/include/mb_config.h.in Sun Aug 01 20:18:59 2010 +0800 +++ b/include/mb_config.h.in Sun Aug 01 20:20:33 2010 +0800 @@ -14,6 +14,9 @@ #undef SH_STEXT /* Enable X backend */ -#undef X_SUPP +#undef X_BACKEND + +/* Enable DirectFB backend */ +#undef DFB_BACKEND #endif /* __MB_CONFIG_H_ */
--- a/include/mb_graph_engine_cairo.h Sun Aug 01 20:18:59 2010 +0800 +++ b/include/mb_graph_engine_cairo.h Sun Aug 01 20:20:33 2010 +0800 @@ -3,12 +3,6 @@ #include <stdio.h> #include <cairo.h> -/* This include file should be remove from here, since it will only be - * used by directfb runtime module. Other modules would not use it. - * FourDollars, please, confirms it. - * - * #include <cairo-directfb.h> - */ #include "mb_basic_types.h" #include "mb_img_ldr.h"
--- a/src/Makefile.am Sun Aug 01 20:18:59 2010 +0800 +++ b/src/Makefile.am Sun Aug 01 20:20:33 2010 +0800 @@ -12,7 +12,7 @@ noinst_PROGRAMS += testcase endif -if X_SUPP +if X_BACKEND MBAF_SOURCES=mbaf/mbapp.c mbaf/mbbutton.c mbaf/mbobject.c mbaf/animated_menu.c else MBAF_SOURCES= @@ -32,7 +32,7 @@ libmbfly_la_SOURCES += shape_stext.c endif -if X_SUPP +if X_BACKEND libmbfly_la_SOURCES += X_supp.c endif