comparison configure @ 20573:14eb4d3ace62

Proper libcdio detection also without pkg-config
author reimar
date Wed, 01 Nov 2006 18:15:06 +0000
parents 595b7c1794fa
children fe90caee5f59
comparison
equal deleted inserted replaced
20572:49c61369d86d 20573:14eb4d3ace62
5305 echores "$_cdparanoia" 5305 echores "$_cdparanoia"
5306 5306
5307 5307
5308 echocheck "libcdio" 5308 echocheck "libcdio"
5309 if test "$_libcdio" = auto && test "$_cdparanoia" = no ; then 5309 if test "$_libcdio" = auto && test "$_cdparanoia" = no ; then
5310 if $_pkg_config --exists libcdio ; then
5311 cat > $TMPC << EOF 5310 cat > $TMPC << EOF
5312 #include <stdio.h> 5311 #include <stdio.h>
5313 #include <cdio/version.h> 5312 #include <cdio/version.h>
5314 #include <cdio/cdda.h> 5313 #include <cdio/cdda.h>
5315 #include <cdio/paranoia.h> 5314 #include <cdio/paranoia.h>
5320 return test == (void *)1; 5319 return test == (void *)1;
5321 5320
5322 } 5321 }
5323 EOF 5322 EOF
5324 _libcdio=no 5323 _libcdio=no
5325 for _inc_tmp in "" "-I/usr/include/cdio" "-I/usr/local/include/cdio" ; do 5324 for _ld_tmp in "-lcdio_cdda -lcdio" "-lcdio_cdda -lcdio -lwinmm" ; do
5326 cc_check `$_pkg_config --cflags --libs libcdio_paranoia` $_inc_tmp $_ld_lm \ 5325 cc_check $_inc_tmp $_ld_tmp $_ld_lm \
5327 && tmp_run && _libcdio=yes && _inc_extra="$_inc_extra $_inc_tmp" && break 5326 && _libcdio=yes && _ld_libcdio="$_ld_tmp" && break
5328 done 5327 done
5329 else 5328 if test "$_libcdio" = no && $_pkg_config --exists libcdio ; then
5330 _libcdio=no 5329 _inc_tmp=`$_pkg_config --cflags libcdio_paranoia`;
5330 _ld_tmp=`$_pkg_config --libs libcdio_paranoia`;
5331 cc_check $_inc_tmp $_ld_tmp $_ld_lm && _libcdio=yes \
5332 && _ld_libcdio="$_ld_tmp" && _inc_extra="$_inc_extra $_inc_tmp" && break
5331 fi 5333 fi
5332 fi 5334 fi
5333 if test "$_libcdio" = yes && test "$_cdparanoia" = no ; then 5335 if test "$_libcdio" = yes && test "$_cdparanoia" = no ; then
5334 _cdda='yes' 5336 _cdda='yes'
5335 _def_libcdio='#define HAVE_LIBCDIO' 5337 _def_libcdio='#define HAVE_LIBCDIO'
5336 _def_havelibcdio='yes' 5338 _def_havelibcdio='yes'
5337 _inc_extra="$_inc_extra `$_pkg_config --cflags libcdio`"
5338 _ld_libcdio=`$_pkg_config --libs libcdio_paranoia`
5339 else 5339 else
5340 if test "$_cdparanoia" = yes ; then 5340 if test "$_cdparanoia" = yes ; then
5341 _res_comment="using cdparanoia" 5341 _res_comment="using cdparanoia"
5342 fi 5342 fi
5343 _def_libcdio='#undef HAVE_LIBCDIO' 5343 _def_libcdio='#undef HAVE_LIBCDIO'