comparison configure @ 19763:b3855eac66ca

detect dvdnav before mpdvdkit and dvdread; if dvdnav is set mplayer will use the version of dvdread embedded in dvdnav
author nicodvb
date Sat, 09 Sep 2006 19:35:55 +0000
parents 4af3191b288d
children 133f4d2f84c5
comparison
equal deleted inserted replaced
19762:59de9ee0ce47 19763:b3855eac66ca
5072 _res_comment="not supported on this OS" 5072 _res_comment="not supported on this OS"
5073 _vcd="no" 5073 _vcd="no"
5074 fi 5074 fi
5075 echores "$_vcd" 5075 echores "$_vcd"
5076 5076
5077 echocheck "DVD support (libdvdnav)"
5078 if test "$_dvdnav" = auto ; then
5079 $_dvdnavconfig --version >> $TMPLOG 2>&1 || _dvdnav=no
5080 fi
5081 if test "$_dvdnav" = auto ; then
5082 cat > $TMPC <<EOF
5083 #include <dvdnav.h>
5084 int main(void) { dvdnav_t *dvd=0; return 0; }
5085 EOF
5086 _dvdnav=no
5087 _dvdnavdir=`$_dvdnavconfig --cflags`
5088 _dvdnavlibs=`$_dvdnavconfig --libs`
5089 _dvdnavvsn=`$_dvdnavconfig --version | sed "s/\.//g"`
5090 _used_css=
5091 _dvdnavmajor=`echo $_dvdnavvsn | cut -d. -f2`
5092 test "$_dvdnavmajor" -ge 2 -o "$_dvdnavvsn" -ge 0110 && \
5093 cc_check -I$_dvdnavdir $_dvdnavlibs $_used_css $_ld_dl $_ld_pthread && _dvdnav=yes
5094 fi
5095 if test "$_dvdnav" = yes ; then
5096 _largefiles=yes
5097 _def_dvdnav='#define USE_DVDNAV 1'
5098 _ld_dvdnav=`$_dvdnavconfig --libs`
5099 _dvdnav_version=`$_dvdnavconfig --version | sed "s/\.//g"`
5100 _def_dvdnav_version="#define DVDNAVVERSION $_dvdnav_version"
5101 _inc_extra="$_inc_extra `$_dvdnavconfig --cflags`"
5102 _inputmodules="dvdnav $_inputmodules"
5103
5104 #disable mpdvdkit and dvdread checks: dvdread will be enabled using dvdnav's version of dvdread
5105 _mpdvdkit=no
5106 _dvdread=yes
5107 else
5108 _def_dvdnav='#undef USE_DVDNAV'
5109 _noinputmodules="dvdnav $_noinputmodules"
5110 fi
5111 echores "$_dvdnav"
5077 5112
5078 echocheck "DVD support (libmpdvdkit2)" 5113 echocheck "DVD support (libmpdvdkit2)"
5079 if test "$_mpdvdkit" = auto ; then 5114 if test "$_mpdvdkit" = auto ; then
5080 _mpdvdkit=no 5115 _mpdvdkit=no
5081 if linux || freebsd || netbsd || darwin || openbsd || win32 || sunos || hpux; then 5116 if linux || freebsd || netbsd || darwin || openbsd || win32 || sunos || hpux; then
5132 _def_mpdvdkit="#undef USE_MPDVDKIT" 5167 _def_mpdvdkit="#undef USE_MPDVDKIT"
5133 case "$_dvdread" in 5168 case "$_dvdread" in
5134 yes) 5169 yes)
5135 _largefiles=yes 5170 _largefiles=yes
5136 _def_dvdread='#define USE_DVDREAD 1' 5171 _def_dvdread='#define USE_DVDREAD 1'
5137 _ld_dvdread='-ldvdread' 5172 if test "$_dvdnav" != yes ; then
5173 _ld_dvdread='-ldvdread'
5174 fi
5138 _inputmodules="dvdread $_inputmodules" 5175 _inputmodules="dvdread $_inputmodules"
5139 _have_dvd=yes 5176 _have_dvd=yes
5140 ;; 5177 ;;
5141 no) 5178 no)
5142 _def_dvdread='#undef USE_DVDREAD' 5179 _def_dvdread='#undef USE_DVDREAD'
5159 _def_have_dvd='#define HAVE_DVD 1' 5196 _def_have_dvd='#define HAVE_DVD 1'
5160 else 5197 else
5161 _def_have_dvd='#undef HAVE_DVD' 5198 _def_have_dvd='#undef HAVE_DVD'
5162 fi 5199 fi
5163 5200
5164 echocheck "DVD support (libdvdnav)"
5165 if test "$_dvdnav" = auto ; then
5166 $_dvdnavconfig --version >> $TMPLOG 2>&1 || _dvdnav=no
5167 fi
5168 if test "$_dvdnav" = auto ; then
5169 cat > $TMPC <<EOF
5170 #include <dvdnav.h>
5171 int main(void) { dvdnav_t *dvd=0; return 0; }
5172 EOF
5173 _dvdnav=no
5174 _dvdnavdir=`$_dvdnavconfig --cflags`
5175 _dvdnavlibs=`$_dvdnavconfig --libs`
5176 _dvdnavvsn=`$_dvdnavconfig --version | sed "s/\.//g"`
5177 _used_css=
5178 _dvdnavmajor=`echo $_dvdnavvsn | cut -d. -f2`
5179 test "$_dvdnavmajor" -ge 2 -o "$_dvdnavvsn" -ge 0110 && \
5180 cc_check -I$_dvdnavdir $_dvdnavlibs $_used_css $_ld_dl $_ld_pthread && _dvdnav=yes
5181 fi
5182 if test "$_dvdnav" = yes ; then
5183 _largefiles=yes
5184 _def_dvdnav='#define USE_DVDNAV 1'
5185 _ld_dvdnav=`$_dvdnavconfig --libs`
5186 _dvdnav_version=`$_dvdnavconfig --version | sed "s/\.//g"`
5187 _def_dvdnav_version="#define DVDNAVVERSION $_dvdnav_version"
5188 _inc_extra="$_inc_extra `$_dvdnavconfig --cflags`"
5189 _inputmodules="dvdnav $_inputmodules"
5190 else
5191 _def_dvdnav='#undef USE_DVDNAV'
5192 _noinputmodules="dvdnav $_noinputmodules"
5193 fi
5194 echores "$_dvdnav"
5195 5201
5196 echocheck "cdparanoia" 5202 echocheck "cdparanoia"
5197 if test "$_cdparanoia" = auto ; then 5203 if test "$_cdparanoia" = auto ; then
5198 cat > $TMPC <<EOF 5204 cat > $TMPC <<EOF
5199 #include <cdda_interface.h> 5205 #include <cdda_interface.h>