[Mplayer-cvslog] CVS: main configure,1.910,1.911
Alexander Strasser
eclipse7 at gmx.net
Mon Sep 20 01:36:35 CEST 2004
Alexander Strasser wrote ( On Thu, Sep 16, 2004 at 10:53:42AM +0200 ):
> Would like to commit the fix, but I think this is flawed anyway:
>
> echocheck "JACK"
> if test "$_jack" = auto ; then
> _jack=no
> if ( ( pkg-config --modversion jack ) > /dev/null 2>&1 ) &&
> ( jackd --version | grep version | awk '{ print $3 }' ) >> "$TMPLOG" 2>&1 ; then
>
> cat > $TMPC << EOF
> #include <jack/jack.h>
> int main(void) { JACK_Init(); return 0; }
> EOF
> # This test only checks the minor version number.
> if ( ( test ! `bio2jack-config --version | cut -d '.' -f 2` -ge 3 ) ) >/dev/null 2>&1 ; then
> _jack=no;
> elif test -z "$_bio2jackdir" ; then
> cc_check -lbio2jack `pkg-config --libs --cflags jack` && ( "$TMPO" >> "$TMPLOG" 2>&1 ) && _jack=yes
> else
> cc_check -L "$_bio2jackdir" -lbio2jack `pkg-config --libs --cflags jack` && ( "$TMPO" >> "$TMPLOG" 2>&1 ) && _jack=yes
> fi
> fi
> fi
>
> - Why do we set _jack to no, even it was initialized to no at beginning
> for the tests to change it to yes eventually, or not?
>
> - And why is the version test in a `if-elif-else'-conditional? That makes
> the version check unable to fail the whole thing alone? Is that really
> intended?
>
> As I thought the version check is there to ensure that a specific version
> must be used, but maybe I'm completely wrong... but confused for sure ;)
Tried to correct it (patch attached), the indentation is stupid but I don't
want to mix up with cosmetics as this always lead to trouble in the past...
so here is my fix, please look over it. But I think I got it right now.
Alex (beastd)
-------------- next part --------------
Index: configure
===================================================================
RCS file: /cvsroot/mplayer/main/configure,v
retrieving revision 1.911
diff -u -w -b -B -r1.911 configure
--- configure 15 Sep 2004 16:01:34 -0000 1.911
+++ configure 19 Sep 2004 23:20:59 -0000
@@ -4277,15 +4277,15 @@
int main(void) { JACK_Init(); return 0; }
EOF
# This test only checks the minor version number.
- if ( ( test ! `bio2jack-config --version | cut -d '.' -f 2` -ge 3 ) ) ; then
- _jack=no;
- elif test -z "$_bio2jackdir" ; then
+ if ( ( test `bio2jack-config --version | cut -d '.' -f 2` -ge 3 ) ) >/dev/null 2>&1 ; then
+ if test -z "$_bio2jackdir" ; then
cc_check -lbio2jack `pkg-config --libs --cflags jack` && ( "$TMPO" >> "$TMPLOG" 2>&1 ) && _jack=yes
else
cc_check -L "$_bio2jackdir" -lbio2jack `pkg-config --libs --cflags jack` && ( "$TMPO" >> "$TMPLOG" 2>&1 ) && _jack=yes
fi
fi
fi
+fi
if test "$_jack" = yes ; then
_def_jack='#define USE_JACK 1'
More information about the MPlayer-cvslog
mailing list