comparison configure.in @ 1606:d91c02552377

ls shouldn't barf if it gets passed a path starting with - (e.g. -lesd)
author Sam Lantinga <slouken@libsdl.org>
date Thu, 23 Mar 2006 21:46:24 +0000
parents cd97a8e39874
children ec3466b08f17
comparison
equal deleted inserted replaced
1605:b70cce8d7f62 1606:d91c02552377
325 elif test "x`ls /usr/local/lib/libasound.so.* 2> /dev/null`" != "x"; then 325 elif test "x`ls /usr/local/lib/libasound.so.* 2> /dev/null`" != "x"; then
326 ALSA_LIBS="-L/usr/local/lib $ALSA_LIBS" 326 ALSA_LIBS="-L/usr/local/lib $ALSA_LIBS"
327 fi 327 fi
328 fi 328 fi
329 alsa_lib_spec=`echo $ALSA_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libasound.so.*/'` 329 alsa_lib_spec=`echo $ALSA_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libasound.so.*/'`
330 alsa_lib=`ls $alsa_lib_spec | sed 's/.*\/\(.*\)/\1/; q'` 330 alsa_lib=`ls -- $alsa_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
331 echo "-- $alsa_lib_spec -> $alsa_lib" 331 echo "-- $alsa_lib_spec -> $alsa_lib"
332 332
333 AC_DEFINE(SDL_AUDIO_DRIVER_ALSA) 333 AC_DEFINE(SDL_AUDIO_DRIVER_ALSA)
334 SOURCES="$SOURCES $srcdir/src/audio/alsa/*.c" 334 SOURCES="$SOURCES $srcdir/src/audio/alsa/*.c"
335 EXTRA_CFLAGS="$EXTRA_CFLAGS $ALSA_CFLAGS" 335 EXTRA_CFLAGS="$EXTRA_CFLAGS $ALSA_CFLAGS"
421 if test x$have_esd = xyes; then 421 if test x$have_esd = xyes; then
422 AC_ARG_ENABLE(esd-shared, 422 AC_ARG_ENABLE(esd-shared,
423 AC_HELP_STRING([--enable-esd-shared], [dynamically load ESD audio support [default=yes]]), 423 AC_HELP_STRING([--enable-esd-shared], [dynamically load ESD audio support [default=yes]]),
424 , enable_esd_shared=yes) 424 , enable_esd_shared=yes)
425 esd_lib_spec=`echo $ESD_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libesd.so.*/'` 425 esd_lib_spec=`echo $ESD_LIBS | sed 's/.*-L\([[^ ]]*\).*/\1\/libesd.so.*/'`
426 esd_lib=`ls $esd_lib_spec | sed 's/.*\/\(.*\)/\1/; q'` 426 esd_lib=`ls -- $esd_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
427 echo "-- $esd_lib_spec -> $esd_lib" 427 echo "-- $esd_lib_spec -> $esd_lib"
428 428
429 AC_DEFINE(SDL_AUDIO_DRIVER_ESD) 429 AC_DEFINE(SDL_AUDIO_DRIVER_ESD)
430 SOURCES="$SOURCES $srcdir/src/audio/esd/*.c" 430 SOURCES="$SOURCES $srcdir/src/audio/esd/*.c"
431 EXTRA_CFLAGS="$EXTRA_CFLAGS $ESD_CFLAGS" 431 EXTRA_CFLAGS="$EXTRA_CFLAGS $ESD_CFLAGS"
473 if test x$audio_arts = xyes; then 473 if test x$audio_arts = xyes; then
474 AC_ARG_ENABLE(arts-shared, 474 AC_ARG_ENABLE(arts-shared,
475 AC_HELP_STRING([--enable-arts-shared], [dynamically load aRts audio support [default=yes]]), 475 AC_HELP_STRING([--enable-arts-shared], [dynamically load aRts audio support [default=yes]]),
476 , enable_arts_shared=yes) 476 , enable_arts_shared=yes)
477 arts_lib_spec="$ARTS_PREFIX/lib/libartsc.so.*" 477 arts_lib_spec="$ARTS_PREFIX/lib/libartsc.so.*"
478 arts_lib=`ls $arts_lib_spec | sed 's/.*\/\(.*\)/\1/; q'` 478 arts_lib=`ls -- $arts_lib_spec | sed 's/.*\/\(.*\)/\1/; q'`
479 echo "-- $arts_lib_spec -> $arts_lib" 479 echo "-- $arts_lib_spec -> $arts_lib"
480 480
481 AC_DEFINE(SDL_AUDIO_DRIVER_ARTS) 481 AC_DEFINE(SDL_AUDIO_DRIVER_ARTS)
482 SOURCES="$SOURCES $srcdir/src/audio/arts/*.c" 482 SOURCES="$SOURCES $srcdir/src/audio/arts/*.c"
483 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARTS_CFLAGS" 483 EXTRA_CFLAGS="$EXTRA_CFLAGS $ARTS_CFLAGS"
805 ;; 805 ;;
806 *) 806 *)
807 x11_lib_spec=[`echo $X_LIBS | sed 's/.*-L\([^ ]*\).*/\1/'`] 807 x11_lib_spec=[`echo $X_LIBS | sed 's/.*-L\([^ ]*\).*/\1/'`]
808 for path in $x11_lib_path /usr/lib /usr/X11/lib /usr/X11R6/lib; do 808 for path in $x11_lib_path /usr/lib /usr/X11/lib /usr/X11R6/lib; do
809 if test "x$x11_lib" = "x"; then 809 if test "x$x11_lib" = "x"; then
810 x11_lib=[`ls $path/libX11.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`] 810 x11_lib=[`ls -- $path/libX11.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`]
811 fi 811 fi
812 if test "x$x11ext_lib" = "x"; then 812 if test "x$x11ext_lib" = "x"; then
813 x11ext_lib=[`ls $path/libXext.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`] 813 x11ext_lib=[`ls -- $path/libXext.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`]
814 fi 814 fi
815 if test "x$xrender_lib" = "x"; then 815 if test "x$xrender_lib" = "x"; then
816 xrender_lib=[`ls $path/libXrender.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`] 816 xrender_lib=[`ls -- $path/libXrender.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`]
817 fi 817 fi
818 if test "x$xrandr_lib" = "x"; then 818 if test "x$xrandr_lib" = "x"; then
819 xrandr_lib=[`ls $path/libXrandr.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`] 819 xrandr_lib=[`ls -- $path/libXrandr.so.[0-9] 2>/dev/null | sort -r | sed 's/.*\/\(.*\)/\1/; q'`]
820 fi 820 fi
821 done 821 done
822 ;; 822 ;;
823 esac 823 esac
824 824