[MPlayer-dev-eng] [PATCH] updated vo_caca for new api patch to use suggested names
Gianluigi Tiesi
mplayer at netfarm.it
Tue Aug 22 03:43:56 CEST 2006
On Sat, Aug 12, 2006 at 01:55:57AM +0200, Gianluigi Tiesi wrote:
> On Thu, Aug 10, 2006 at 09:55:37PM -0600, Sean D'Epagnier wrote:
> > On Thu, Aug 10, 2006 at 06:48:34PM +0200, Gianluigi Tiesi wrote:
> > > imho it should be splitted in two files, like alsa ao
> > >
> >
> > Do you mean like fbdev and fbdev2 for two separate output plugins?
> >
> > Sean
> yes but more like alsa or alsa5 depending on the detection,
> the code is very different and almost all the source file
> is ifdefed
>
> Bye
I've made a patch for configure
attached is vo_caca.c that is for new up
libvo/vo_caca.c should be renamed to libvo/vo_caca9.c
and the attached filed should replace libvo/vo_caca.c
feel free to use vo_caca1x.c instead of renaming
but I've done the patch following the alsa convention
compiles fine on linux need to test it on mingw
Bye
--
Gianluigi Tiesi <sherpya at netfarm.it>
EDP Project Leader
Netfarm S.r.l. - http://www.netfarm.it/
Free Software: http://oss.netfarm.it/
-------------- next part --------------
Index: configure
===================================================================
--- configure (revision 19491)
+++ configure (working copy)
@@ -4140,21 +4140,43 @@
echocheck "CACA"
-if test "$_caca" = auto ; then
+if test "$_caca" = auto || test "$_caca" = yes ; then
_caca=no
if ( caca-config --version ) >> "$TMPLOG" 2>&1 ; then
+
cat > $TMPC << EOF
#include <caca.h>
-int main(void) { (void) caca_init(); return 0; }
+int main(void)
+{
+#ifndef CACA_API_VERSION_1
+#error "Caca version 1.x check failed"
+#endif
+ (void) cucul_create_canvas(0, 0);
+ return 0;
+}
EOF
- cc_check `caca-config --libs` && _caca=yes
+ cc_check `caca-config --libs` && _cacaver='1x'
+
+ cat > $TMPC << EOF
+#include <caca.h>
+int main(void){ (void) caca_init(); return 0; }
+EOF
+ cc_check `caca-config --libs` && _cacaver='09'
+
fi
fi
-if test "$_caca" = yes ; then
+if test "$_cacaver" ; then
+ _caca=yes
_def_caca='#define HAVE_CACA 1'
_inc_extra="$_inc_extra `caca-config --cflags`"
_ld_caca=`caca-config --libs`
- _vosrc="$_vosrc vo_caca.c"
+ if test "$_cacaver" = '1x' ; then
+ _vosrc="$_vosrc vo_caca.c"
+ _res_comment="using 1x api"
+ else
+ _vosrc="$_vosrc vo_caca9.c"
+ _res_comment="using old api"
+ fi
_vomodules="caca $_vomodules"
else
_def_caca='#undef HAVE_CACA'
@@ -4162,7 +4184,6 @@
fi
echores "$_caca"
-
echocheck "SVGAlib"
if test "$_svga" = auto ; then
cat > $TMPC << EOF
-------------- next part --------------
A non-text attachment was scrubbed...
Name: vo_caca.c
Type: text/x-csrc
Size: 8096 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/mplayer-dev-eng/attachments/20060822/928bae52/attachment.c>
More information about the MPlayer-dev-eng
mailing list