dfa8040fc6
on DVDs. ok biorn@
210 lines
7.3 KiB
Plaintext
210 lines
7.3 KiB
Plaintext
$OpenBSD: patch-configure,v 1.52 2009/07/14 19:43:07 naddy Exp $
|
|
--- configure.orig Sun Oct 7 21:49:33 2007
|
|
+++ configure Mon Jul 13 23:49:43 2009
|
|
@@ -76,7 +76,7 @@ cc_check() {
|
|
}
|
|
|
|
cxx_check() {
|
|
- compile_check $TMPCPP $@ -lstdc++
|
|
+ compile_check $TMPCPP $@ -lstdc++ -lm
|
|
}
|
|
|
|
tmp_run() {
|
|
@@ -397,6 +397,7 @@ Audio output:
|
|
--disable-nas disable NAS audio output [autodetect]
|
|
--disable-sgiaudio disable SGI audio output [autodetect]
|
|
--disable-sunaudio disable Sun audio output [autodetect]
|
|
+ --disable-libsndio disable libsndio audio output [autodetect]
|
|
--disable-win32waveout disable Windows waveout audio output [autodetect]
|
|
--disable-select disable using select() on the audio device [enable]
|
|
|
|
@@ -501,7 +502,7 @@ _libavcodec_a=auto
|
|
_libamr_nb=auto
|
|
_libamr_wb=auto
|
|
_libavdecoders_all=`sed -n 's/^[^#]*DEC.*(.*, *\(.*\)).*/\1_decoder/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`
|
|
-_libavdecoders=` echo $_libavdecoders_all | sed -e s/LIBFAAD_DECODER// -e s/MPEG4AAC_DECODER// -e s/LIBA52_DECODER// -e s/LIBGSM_DECODER// -e s/LIBGSM_MS_DECODER// -e s/LIBVORBIS_DECODER// `
|
|
+_libavdecoders=` echo $_libavdecoders_all | sed -e s/LIBFAAD_DECODER// -e s/MPEG4AAC_DECODER// -e s/LIBA52_DECODER// -e s/LIBGSM_DECODER// -e s/LIBGSM_MS_DECODER// -e s/LIBVORBIS_DECODER// -e s/VORBIS_DECODER// `
|
|
_libavencoders_all=`sed -n 's/^[^#]*ENC.*(.*, *\(.*\)).*/\1_encoder/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`
|
|
_libavencoders=` echo $_libavencoders_all | sed -e s/LIBGSM_ENCODER// -e s/LIBGSM_MS_ENCODER// -e s/LIBTHEORA_ENCODER// `
|
|
_libavparsers_all=`sed -n 's/^[^#]*PARSER.*(.*, *\(.*\)).*/\1_parser/p' libavcodec/allcodecs.c | tr '[a-z]' '[A-Z]'`
|
|
@@ -598,6 +599,7 @@ _xf86keysym=auto
|
|
_mlib=no #broken, thus disabled
|
|
_sgiaudio=auto
|
|
_sunaudio=auto
|
|
+_libsndio=auto
|
|
_alsa=auto
|
|
_fastmemcpy=yes
|
|
_unrarlib=yes
|
|
@@ -963,6 +965,8 @@ for ac_option do
|
|
--disable-mlib) _mlib=no ;;
|
|
--enable-sunaudio) _sunaudio=yes ;;
|
|
--disable-sunaudio) _sunaudio=no ;;
|
|
+ --enable-libsndio) _libsndio=yes ;;
|
|
+ --disable-libsndio) _libsndio=no ;;
|
|
--enable-sgiaudio) _sgiaudio=yes ;;
|
|
--disable-sgiaudio) _sgiaudio=no ;;
|
|
--enable-alsa) _alsa=yes ;;
|
|
@@ -1557,6 +1561,8 @@ if x86 ; then
|
|
pparam=`echo $exts | sed -e s/k6_mtrr/mtrr/ -e s/cyrix_arr/mtrr/ -e s/centaur_mcr/mtrr/ \
|
|
-e s/xmm/sse/ -e s/kni/sse/`
|
|
|
|
+ if x86_64 ; then pparam="3dnow 3dnowext mmx mmxext xmm sse sse2" ; fi
|
|
+
|
|
for ext in $pparam ; do
|
|
eval test \"\$_$ext\" = auto 2>/dev/null && eval _$ext=kernel_check
|
|
done
|
|
@@ -2323,7 +2329,7 @@ fi # if darwin && test "$cc_vendor" = "gnu" ; then
|
|
# Checking for CFLAGS
|
|
_install_strip="-s"
|
|
if test "$_profile" != "" || test "$_debug" != "" ; then
|
|
- CFLAGS="-W -Wall -O2 $_march $_mcpu $_pipe $_debug $_profile"
|
|
+ CFLAGS="-W -Wall -O1 $_march $_mcpu $_pipe $_debug $_profile"
|
|
_install_strip=
|
|
elif test -z "$CFLAGS" ; then
|
|
if test "$cc_vendor" = "intel" ; then
|
|
@@ -3065,7 +3071,7 @@ int main(void) { pthread_t tid; return pthread_create
|
|
EOF
|
|
_pthreads=no
|
|
if not hpux ; then
|
|
- for _ld_tmp in "-lpthreadGC2" "" "-lpthread" "-pthread" ; do
|
|
+ for _ld_tmp in "-lpthreadGC2" "" "-pthread" "-lpthread" ; do
|
|
# for crosscompilation, we cannot execute the program, be happy if we can link statically
|
|
cc_check $_ld_tmp && (tmp_run || test "$_ld_static") && _ld_pthread="$_ld_tmp" && _pthreads=yes && break
|
|
done
|
|
@@ -3108,7 +3114,7 @@ fi
|
|
echores "$_rpath"
|
|
|
|
echocheck "iconv"
|
|
-if test "$_iconv" = auto ; then
|
|
+if test "$_iconv" != no ; then
|
|
cat > $TMPC << EOF
|
|
#include <stdio.h>
|
|
#include <unistd.h>
|
|
@@ -4369,6 +4375,8 @@ if test "$_aa" = yes ; then
|
|
_def_aa='#define HAVE_AA 1'
|
|
if cygwin ; then
|
|
_libs_mplayer="$_libs_mplayer `aalib-config --libs | cut -d " " -f 2,5,6`"
|
|
+ else
|
|
+ _libs_mplayer="$_libs_mplayer -laa"
|
|
fi
|
|
_vosrc="$_vosrc vo_aa.c"
|
|
_vomodules="aa $_vomodules"
|
|
@@ -4576,7 +4584,7 @@ fi
|
|
echores "$_png"
|
|
if test "$_png" = yes ; then
|
|
_def_png='#define HAVE_PNG 1'
|
|
- _ld_extra="$_ld_extra -lpng -lz"
|
|
+ _ld_extra="$_ld_extra -lpng -lz $_ld_lm"
|
|
_vosrc="$_vosrc vo_png.c"
|
|
_vomodules="png $_vomodules"
|
|
else
|
|
@@ -5129,7 +5137,8 @@ fi
|
|
echocheck "JACK"
|
|
if test "$_jack" = auto ; then
|
|
_jack=yes
|
|
-
|
|
+fi
|
|
+if test "$_jack" = yes ; then
|
|
cat > $TMPC << EOF
|
|
#include <jack/jack.h>
|
|
int main(void) { jack_client_new("test"); return 0; }
|
|
@@ -5303,6 +5312,27 @@ fi
|
|
echores "$_sunaudio"
|
|
|
|
|
|
+echocheck "libsndio audio"
|
|
+if test "$_libsndio" = auto ; then
|
|
+ cat > $TMPC << EOF
|
|
+#include <sndio.h>
|
|
+int main(void) { struct sio_par par; sio_initpar(&par); return 0; }
|
|
+EOF
|
|
+ _libsndio=no
|
|
+ cc_check -lsndio && _libsndio=yes
|
|
+fi
|
|
+if test "$_libsndio" = yes ; then
|
|
+ _def_libsndio='#define USE_LIBSNDIO_AUDIO 1'
|
|
+ _aosrc="$_aosrc ao_libsndio.c"
|
|
+ _aomodules="libsndio $_aomodules"
|
|
+ _libs_mplayer="$_libs_mplayer -lsndio"
|
|
+else
|
|
+ _def_libsndio='#undef USE_LIBSNDIO_AUDIO'
|
|
+ _noaomodules="libsndio $_noaomodules"
|
|
+fi
|
|
+echores "$_libsndio"
|
|
+
|
|
+
|
|
if sunos; then
|
|
echocheck "Sun mediaLib"
|
|
if test "$_mlib" = auto ; then
|
|
@@ -5343,7 +5373,7 @@ fi #if irix
|
|
|
|
|
|
echocheck "VCD support"
|
|
-if linux || bsdos || freebsd || netbsd || sunos || darwin || mingw32; then
|
|
+if linux || bsdos || freebsd || netbsd || sunos || darwin || mingw32 || openbsd ; then
|
|
_inputmodules="vcd $_inputmodules"
|
|
_def_vcd='#define HAVE_VCD 1'
|
|
_vcd="yes"
|
|
@@ -5592,7 +5622,7 @@ int main()
|
|
}
|
|
EOF
|
|
_fontconfig=no
|
|
- for _ld_tmp in "" "-lexpat -lfreetype" "-lexpat -lfreetype -lz" ; do
|
|
+ for _ld_tmp in "" "-lexpat -lfreetype" "-lexpat -lfreetype -lz $_ld_lm" ; do
|
|
_ld_tmp="-lfontconfig $_ld_tmp"
|
|
cc_check $_ld_tmp && _fontconfig=yes && _ld_extra="$_ld_extra $_ld_tmp" && break
|
|
done
|
|
@@ -5704,10 +5734,10 @@ cat > $TMPC << EOF
|
|
int main(void) { (void) inflate(0, Z_NO_FLUSH); return 0; }
|
|
EOF
|
|
_zlib=no
|
|
-cc_check -lz && _zlib=yes
|
|
+cc_check "-lz $_ld_lm" && _zlib=yes
|
|
if test "$_zlib" = yes ; then
|
|
_def_zlib='#define HAVE_ZLIB 1'
|
|
- _ld_extra="$_ld_extra -lz"
|
|
+ _ld_extra="$_ld_extra -lz $_ld_lm"
|
|
else
|
|
_def_zlib='#undef HAVE_ZLIB'
|
|
_libavdecoders=`echo $_libavdecoders | sed -e s/FLASHSV_DECODER// -e s/PNG_DECODER// -e s/ZMBV_DECODER// -e s/DXA_DECODER// `
|
|
@@ -5986,11 +6016,11 @@ if test "$_libdca" = auto ; then
|
|
#include <dts.h>
|
|
int main(void) { dts_init (0); return 0; }
|
|
EOF
|
|
- cc_check -ldts $_ld_lm && _libdca=yes
|
|
+ cc_check -ldca $_ld_lm && _libdca=yes
|
|
fi
|
|
if test "$_libdca" = yes ; then
|
|
_def_libdca='#define USE_LIBDCA 1'
|
|
- _ld_extra="$_ld_extra -ldts"
|
|
+ _ld_extra="$_ld_extra -ldca"
|
|
_codecmodules="libdca $_codecmodules"
|
|
else
|
|
_def_libdca='#undef USE_LIBDCA'
|
|
@@ -6207,7 +6237,7 @@ if test "$_real" = auto ; then
|
|
_real=no
|
|
_res_comment="dynamic loader support needed"
|
|
if test "$_dl" = yes || test "$_win32dll" = yes &&
|
|
- (linux || freebsd || netbsd || win32 || darwin) ; then
|
|
+ (linux || freebsd || netbsd || openbsd || win32 || darwin) ; then
|
|
_real=yes
|
|
fi
|
|
fi
|
|
@@ -8151,6 +8181,7 @@ $_def_openal_h
|
|
$_def_sys_asoundlib_h
|
|
$_def_alsa_asoundlib_h
|
|
$_def_sunaudio
|
|
+$_def_libsndio
|
|
$_def_sgiaudio
|
|
$_def_win32waveout
|
|
$_def_nas
|
|
@@ -8240,7 +8271,7 @@ $_def_vcd
|
|
#define DEFAULT_CDROM_DEVICE "/dev/disk1"
|
|
#define DEFAULT_DVD_DEVICE "/dev/rdiskN"
|
|
#elif defined(__OpenBSD__)
|
|
-#define DEFAULT_CDROM_DEVICE "/dev/rcd0a"
|
|
+#define DEFAULT_CDROM_DEVICE "/dev/rcd0c"
|
|
#define DEFAULT_DVD_DEVICE DEFAULT_CDROM_DEVICE
|
|
#elif defined(__FreeBSD__) || defined(__FreeBSD_kernel__)
|
|
#define DEFAULT_CDROM_DEVICE "/dev/acd0"
|