Commit 8cc8d957 authored by Sam Hocevar's avatar Sam Hocevar

  * ./configure.in: removed a bashism.
  * ./plugins/x11/xcommon.c: support for systems without shm.h.
  * QNX compilation fixes here and there; the qnx plugin still doesn't work.
parent 38ed5ffc
......@@ -45,6 +45,7 @@ PLUGINS_DIR := ac3_adec \
mpeg_system \
mpeg_adec \
mpeg_vdec \
qnx \
qt \
sdl \
spudec \
......@@ -116,6 +117,7 @@ PLUGINS_TARGETS := ac3_adec/ac3_adec \
mpeg_system/mpeg_ts \
mpeg_adec/mpeg_adec \
mpeg_vdec/mpeg_vdec \
qnx/qnx \
qt/qt \
sdl/sdl \
spudec/spudec \
......
......@@ -74,7 +74,7 @@ $(SRC_CPP:%.cpp=%.$(suff).$(module_name)): %.$(suff).$(module_name): %.cpp
$(CC) $(CFLAGS) $(CFLAGS_EXTRA) -c $< -o $@
../$(module_name).so: $(EXTRA_DEP) $(OBJ_ALL)
$(CC) $(OBJ_ALL) $(PLDFLAGS) $(LIB_$(MODULE_NAME)) -o $@ && chmod -x $@
$(CC) $(OBJ_ALL) $(PLDFLAGS) $(LIB_$(MODULE_NAME)) -o $@ && chmod a-x $@
../$(module_name).a: $(EXTRA_DEP) $(OBJ_ALL)
rm -f $@ && ar rc $@ $(OBJ_ALL) && $(RANLIB) $@
......
......@@ -4530,7 +4530,7 @@ else
fi
done
for ac_hdr in machine/param.h
for ac_hdr in machine/param.h sys/shm.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
......@@ -6566,17 +6566,17 @@ if test "${with_mad+set}" = set; then
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6564: checking for $ac_hdr" >&5
echo "configure:6570: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 6569 "configure"
#line 6575 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6574: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:6580: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -6606,7 +6606,7 @@ fi
done
echo $ac_n "checking for mad_bit_init in -lmad""... $ac_c" 1>&6
echo "configure:6604: checking for mad_bit_init in -lmad" >&5
echo "configure:6610: checking for mad_bit_init in -lmad" >&5
ac_lib_var=`echo mad'_'mad_bit_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -6614,7 +6614,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lmad $LIBS"
cat > conftest.$ac_ext <<EOF
#line 6612 "configure"
#line 6618 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
......@@ -6625,7 +6625,7 @@ int main() {
mad_bit_init()
; return 0; }
EOF
if { (eval echo configure:6623: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:6629: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
......@@ -6682,17 +6682,17 @@ then
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6680: checking for $ac_hdr" >&5
echo "configure:6686: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 6685 "configure"
#line 6691 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6690: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:6696: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -6730,7 +6730,7 @@ if test "${enable_esd+set}" = set; then
# Extract the first word of "esd-config", so it can be a program name with args.
set dummy esd-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:6728: checking for $ac_word" >&5
echo "configure:6734: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_ESD_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -6781,7 +6781,7 @@ if test "${enable_arts+set}" = set; then
# Extract the first word of "artsc-config", so it can be a program name with args.
set dummy artsc-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:6779: checking for $ac_word" >&5
echo "configure:6785: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_ARTS_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -6839,17 +6839,17 @@ else
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6837: checking for $ac_hdr" >&5
echo "configure:6843: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 6842 "configure"
#line 6848 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6847: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:6853: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -6894,17 +6894,17 @@ fi
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6892: checking for $ac_hdr" >&5
echo "configure:6898: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 6897 "configure"
#line 6903 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6902: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:6908: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -6941,23 +6941,23 @@ if test "${enable_a52+set}" = set; then
:
fi
if ((test "x$enableval" != "xno") && (test x$SYS != xmingw32))
if test "x$enableval" != "xno" -a x$SYS != xmingw32
then
for ac_hdr in a52dec/a52.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:6945: checking for $ac_hdr" >&5
echo "configure:6951: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 6950 "configure"
#line 6956 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:6955: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:6961: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7045,7 +7045,7 @@ fi
# Extract the first word of "sdl12-config", so it can be a program name with args.
set dummy sdl12-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:7043: checking for $ac_word" >&5
echo "configure:7049: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SDL12_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -7085,7 +7085,7 @@ fi
# Extract the first word of "sdl11-config", so it can be a program name with args.
set dummy sdl11-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:7083: checking for $ac_word" >&5
echo "configure:7089: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SDL11_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -7126,7 +7126,7 @@ fi
# Extract the first word of "sdl-config", so it can be a program name with args.
set dummy sdl-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:7124: checking for $ac_word" >&5
echo "configure:7130: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_SDL_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -7172,17 +7172,17 @@ fi
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7170: checking for $ac_hdr" >&5
echo "configure:7176: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7175 "configure"
#line 7181 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7180: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7186: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7252,17 +7252,17 @@ fi
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7250: checking for $ac_hdr" >&5
echo "configure:7256: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7255 "configure"
#line 7261 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7260: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7266: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7291,7 +7291,7 @@ done
else
echo $ac_n "checking for directX headers in ${withval}""... $ac_c" 1>&6
echo "configure:7289: checking for directX headers in ${withval}" >&5
echo "configure:7295: checking for directX headers in ${withval}" >&5
if test -f ${withval}/include/ddraw.h
then
PLUGINS="${PLUGINS} directx"
......@@ -7312,7 +7312,7 @@ if test "${enable_waveout+set}" = set; then
:
fi
if ((test "x$enableval" != "xno") && (test x$SYS = xmingw32))
if test "x$enableval" != "xno" -a x$SYS = xmingw32
then
PLUGINS="${PLUGINS} waveout"
LIB_WAVEOUT="-lwinmm"
......@@ -7400,7 +7400,7 @@ if test "${enable_gnome+set}" = set; then
# Extract the first word of "gnome-config", so it can be a program name with args.
set dummy gnome-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:7398: checking for $ac_word" >&5
echo "configure:7404: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GNOME_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -7445,17 +7445,17 @@ fi
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7443: checking for $ac_hdr" >&5
echo "configure:7449: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7448 "configure"
#line 7454 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7453: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7459: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7515,7 +7515,7 @@ fi
# Extract the first word of "gtk-config", so it can be a program name with args.
set dummy gtk-config; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:7513: checking for $ac_word" >&5
echo "configure:7519: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_path_GTK_CONFIG'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -7565,17 +7565,17 @@ fi
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7563: checking for $ac_hdr" >&5
echo "configure:7569: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7568 "configure"
#line 7574 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7573: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7579: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7632,17 +7632,17 @@ if test x$enable_x11 != xno &&
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7630: checking for $ac_hdr" >&5
echo "configure:7636: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7635 "configure"
#line 7641 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7640: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7646: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7695,17 +7695,17 @@ if test x$enable_xvideo != xno &&
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:7693: checking for $ac_hdr" >&5
echo "configure:7699: checking for $ac_hdr" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7698 "configure"
#line 7704 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7703: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7709: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7729,7 +7729,7 @@ EOF
saved_CFLAGS=$CFLAGS
CFLAGS="$CFLAGS -L$x_libraries -lX11 -lXext"
echo $ac_n "checking for XvSetPortAttribute in -lXv_pic""... $ac_c" 1>&6
echo "configure:7727: checking for XvSetPortAttribute in -lXv_pic" >&5
echo "configure:7733: checking for XvSetPortAttribute in -lXv_pic" >&5
ac_lib_var=`echo Xv_pic'_'XvSetPortAttribute | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -7737,7 +7737,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lXv_pic $LIBS"
cat > conftest.$ac_ext <<EOF
#line 7735 "configure"
#line 7741 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
......@@ -7748,7 +7748,7 @@ int main() {
XvSetPortAttribute()
; return 0; }
EOF
if { (eval echo configure:7746: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:7752: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
......@@ -7795,17 +7795,17 @@ if test x$enable_lirc = xyes
then
ac_safe=`echo "lirc/lirc_client.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for lirc/lirc_client.h""... $ac_c" 1>&6
echo "configure:7793: checking for lirc/lirc_client.h" >&5
echo "configure:7799: checking for lirc/lirc_client.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7798 "configure"
#line 7804 "configure"
#include "confdefs.h"
#include <lirc/lirc_client.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7803: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7809: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7822,7 +7822,7 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for lirc_init in -llirc_client""... $ac_c" 1>&6
echo "configure:7820: checking for lirc_init in -llirc_client" >&5
echo "configure:7826: checking for lirc_init in -llirc_client" >&5
ac_lib_var=`echo lirc_client'_'lirc_init | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -7830,7 +7830,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-llirc_client $LIBS"
cat > conftest.$ac_ext <<EOF
#line 7828 "configure"
#line 7834 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
......@@ -7841,7 +7841,7 @@ int main() {
lirc_init()
; return 0; }
EOF
if { (eval echo configure:7839: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:7845: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
......@@ -7881,17 +7881,17 @@ if test "${enable_alsa+set}" = set; then
then
ac_safe=`echo "alsa/asoundlib.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for alsa/asoundlib.h""... $ac_c" 1>&6
echo "configure:7879: checking for alsa/asoundlib.h" >&5
echo "configure:7885: checking for alsa/asoundlib.h" >&5
if eval "test \"`echo '$''{'ac_cv_header_$ac_safe'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 7884 "configure"
#line 7890 "configure"
#include "confdefs.h"
#include <alsa/asoundlib.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:7889: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:7895: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
ac_err=`grep -v '^ *+' conftest.out | grep -v "^conftest.${ac_ext}\$"`
if test -z "$ac_err"; then
rm -rf conftest*
......@@ -7908,7 +7908,7 @@ fi
if eval "test \"`echo '$ac_cv_header_'$ac_safe`\" = yes"; then
echo "$ac_t""yes" 1>&6
echo $ac_n "checking for main in -lasound""... $ac_c" 1>&6
echo "configure:7906: checking for main in -lasound" >&5
echo "configure:7912: checking for main in -lasound" >&5
ac_lib_var=`echo asound'_'main | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -7916,14 +7916,14 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lasound $LIBS"
cat > conftest.$ac_ext <<EOF
#line 7914 "configure"
#line 7920 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
if { (eval echo configure:7921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:7927: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_lib_$ac_lib_var=yes"
else
......@@ -8094,6 +8094,7 @@ PLUGIN_PATH="${ac_tool_prefix}/share/videolan"
trap '' 1 2 15
......
......@@ -177,7 +177,7 @@ AC_CHECK_HEADERS(sys/sockio.h fcntl.h sys/time.h sys/times.h)
AC_CHECK_HEADERS(sys/soundcard.h machine/soundcard.h)
AC_CHECK_HEADERS(dlfcn.h image.h)
AC_CHECK_HEADERS(arpa/inet.h net/if.h netinet/in.h sys/socket.h)
AC_CHECK_HEADERS(machine/param.h)
AC_CHECK_HEADERS(machine/param.h sys/shm.h)
AC_HEADER_TIME
......@@ -1074,7 +1074,7 @@ dnl a52 AC3 decoder plugin
dnl
AC_ARG_ENABLE(a52,
[ --disable-a52 AC3 support with liba52 (default enabled)])
if ((test "x$enableval" != "xno") && (test x$SYS != xmingw32))
if test "x$enableval" != "xno" -a x$SYS != xmingw32
then
AC_CHECK_HEADERS(a52dec/a52.h, [
BUILTINS="${BUILTINS} a52"
......@@ -1211,7 +1211,7 @@ dnl win32 waveOut plugin
dnl
AC_ARG_ENABLE(waveout,
[ --disable-waveout Win32 waveOut module (default enabled on Win32)])
if ((test "x$enableval" != "xno") && (test x$SYS = xmingw32))
if test "x$enableval" != "xno" -a x$SYS = xmingw32
then
PLUGINS="${PLUGINS} waveout"
LIB_WAVEOUT="-lwinmm"
......
......@@ -3,7 +3,7 @@
* Collection of useful common types and macros definitions
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: common.h,v 1.74 2002/02/19 00:50:18 sam Exp $
* $Id: common.h,v 1.75 2002/02/20 23:23:53 sam Exp $
*
* Authors: Samuel Hocevar <sam@via.ecp.fr>
* Vincent Seguin <seguin@via.ecp.fr>
......@@ -28,6 +28,7 @@
* Required system headers
*****************************************************************************/
#include <string.h> /* strerror() */
#include <sys/types.h>
/*****************************************************************************
* Basic types definitions
......@@ -37,7 +38,7 @@ typedef u8 byte_t;
/* Boolean type */
#ifdef BOOLEAN_T_IN_SYS_TYPES_H
# include <sys/types.h>
# /* <sys/types.h> already included */
#elif defined(BOOLEAN_T_IN_PTHREAD_H)
# include <pthread.h>
#elif defined(BOOLEAN_T_IN_CTHREADS_H)
......
/* include/defs.h.in. Generated automatically from configure.in by autoheader 2.13. */
/* include/defs.h.in. Generated automatically from configure.in by autoheader. */
/* Define if using alloca.c. */
#undef C_ALLOCA
......@@ -283,6 +283,9 @@
/* Define if you have the <sys/param.h> header file. */
#undef HAVE_SYS_PARAM_H
/* Define if you have the <sys/shm.h> header file. */
#undef HAVE_SYS_SHM_H
/* Define if you have the <sys/socket.h> header file. */
#undef HAVE_SYS_SOCKET_H
......
......@@ -2,7 +2,7 @@
* xcommon.c: Functions common to the X11 and XVideo plugins
*****************************************************************************
* Copyright (C) 1998-2001 VideoLAN
* $Id: xcommon.c,v 1.17 2002/02/19 00:50:19 sam Exp $
* $Id: xcommon.c,v 1.18 2002/02/20 23:23:53 sam Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -34,21 +34,26 @@
#include <videolan/vlc.h>
#ifdef HAVE_MACHINE_PARAM_H
/* BSD */
#include <machine/param.h>
#include <sys/types.h> /* typedef ushort */
#include <sys/ipc.h>
/* BSD */
# include <machine/param.h>
# include <sys/types.h> /* typedef ushort */
# include <sys/ipc.h>
#endif
#ifndef WIN32
#include <netinet/in.h> /* BSD: struct in_addr */
# include <netinet/in.h> /* BSD: struct in_addr */
#endif
#ifdef HAVE_SYS_SHM_H
# include <sys/shm.h> /* shmget(), shmctl() */
#endif
#include <sys/shm.h> /* shmget(), shmctl() */
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/keysym.h>
#include <X11/extensions/XShm.h>
#ifdef HAVE_SYS_SHM_H
# include <X11/extensions/XShm.h>
#endif
#ifdef DPMSINFO_IN_DPMS_H
# include <X11/extensions/dpms.h>
#endif
......@@ -102,7 +107,9 @@ static int NewPicture ( vout_thread_t *, picture_t * );
static void FreePicture ( vout_thread_t *, picture_t * );
static IMAGE_TYPE *CreateImage ( Display *, EXTRA_ARGS, int, int );
#ifdef HAVE_SYS_SHM_H
static IMAGE_TYPE *CreateShmImage ( Display *, EXTRA_ARGS_SHM, int, int );
#endif
static void ToggleFullScreen ( vout_thread_t * );
......@@ -134,7 +141,9 @@ typedef struct vout_sys_s
Window window; /* root window */
GC gc; /* graphic context instance handler */
#ifdef HAVE_SYS_SHM_H
boolean_t b_shm; /* shared memory extension flag */
#endif
#ifdef MODULE_NAME_IS_xvideo
Window yuv_window; /* sub-window for displaying yuv video
......@@ -195,7 +204,9 @@ typedef struct picture_sys_s
{
IMAGE_TYPE * p_image;
#ifdef HAVE_SYS_SHM_H
XShmSegmentInfo shminfo; /* shared memory zone information */
#endif
} picture_sys_t;
......@@ -496,25 +507,27 @@ static void vout_Display( vout_thread_t *p_vout, picture_t *p_pic )
vout_PlacePicture( p_vout, p_vout->p_sys->i_width, p_vout->p_sys->i_height,
&i_x, &i_y, &i_width, &i_height );
#ifdef HAVE_SYS_SHM_H
if( p_vout->p_sys->b_shm )
{
/* Display rendered image using shared memory extension */
#ifdef MODULE_NAME_IS_xvideo
# ifdef MODULE_NAME_IS_xvideo
XvShmPutImage( p_vout->p_sys->p_display, p_vout->p_sys->i_xvport,
p_vout->p_sys->yuv_window, p_vout->p_sys->gc,
p_pic->p_sys->p_image, 0 /*src_x*/, 0 /*src_y*/,
p_vout->output.i_width, p_vout->output.i_height,
0 /*dest_x*/, 0 /*dest_y*/, i_width, i_height,
False /* Don't put True here or you'll waste your CPU */ );
#else
# else
XShmPutImage( p_vout->p_sys->p_display, p_vout->p_sys->window,
p_vout->p_sys->gc, p_pic->p_sys->p_image,
0 /*src_x*/, 0 /*src_y*/, 0 /*dest_x*/, 0 /*dest_y*/,
p_vout->output.i_width, p_vout->output.i_height,
False /* Don't put True here ! */ );
#endif
# endif
}
else
#endif /* HAVE_SYS_SHM_H */
{
/* Use standard XPutImage -- this is gonna be slow ! */
#ifdef MODULE_NAME_IS_xvideo
......@@ -1128,22 +1141,24 @@ static int NewPicture( vout_thread_t *p_vout, picture_t *p_pic )
return -1;
}
#ifdef HAVE_SYS_SHM_H
if( p_vout->p_sys->b_shm )
{
/* Create image using XShm extension */
p_pic->p_sys->p_image =
CreateShmImage( p_vout->p_sys->p_display,
#ifdef MODULE_NAME_IS_xvideo
# ifdef MODULE_NAME_IS_xvideo
p_vout->p_sys->i_xvport,
p_vout->output.i_chroma,
#else
# else
p_vout->p_sys->p_visual,
p_vout->p_sys->i_screen_depth,
#endif
# endif
&p_pic->p_sys->shminfo,
p_vout->output.i_width, p_vout->output.i_height );
}
else
#endif /* HAVE_SYS_SHM_H */
{
/* Create image without XShm extension */
p_pic->p_sys->p_image =
......@@ -1360,6 +1375,7 @@ static int NewPicture( vout_thread_t *p_vout, picture_t *p_pic )
static void FreePicture( vout_thread_t *p_vout, picture_t *p_pic )
{
/* The order of operations is correct */
#ifdef HAVE_SYS_SHM_H
if( p_vout->p_sys->b_shm )
{
XShmDetach( p_vout->p_sys->p_display, &p_pic->p_sys->shminfo );
......@@ -1373,6 +1389,7 @@ static void FreePicture( vout_thread_t *p_vout, picture_t *p_pic )
}
}
else
#endif
{
IMAGE_FREE( p_pic->p_sys->p_image );
}
......@@ -1986,14 +2003,16 @@ static int InitDisplay( vout_thread_t *p_vout )
int i_count; /* array size */
#endif
#ifdef SYS_DARWIN
#ifdef HAVE_SYS_SHM_H
# ifdef SYS_DARWIN
/* FIXME : As of 2001-03-16, XFree4 for MacOS X does not support Xshm. */
p_vout->p_sys->b_shm = 0;
#else
# else
p_vout->p_sys->b_shm = ( XShmQueryExtension( p_vout->p_sys->p_display )
== True );
#endif
# endif
if( !p_vout->p_sys->b_shm )
#endif
{
intf_WarnMsg( 1, "vout warning: XShm video extension is unavailable" );
}
......@@ -2082,6 +2101,7 @@ static int InitDisplay( vout_thread_t *p_vout )
return( 0 );
}
#ifdef HAVE_SYS_SHM_H
/*****************************************************************************
* CreateShmImage: create an XImage or XvImage using shared memory extension
*****************************************************************************
......@@ -2157,6 +2177,7 @@ static IMAGE_TYPE * CreateShmImage( Display* p_display, EXTRA_ARGS_SHM,
return( p_image );
}
#endif
/*****************************************************************************
* CreateImage: create an XImage or XvImage
......
......@@ -2,7 +2,7 @@
* netutils.c: various network functions
*****************************************************************************
* Copyright (C) 1999-2001 VideoLAN
* $Id: netutils.c,v 1.55 2002/01/13 18:13:07 gbazin Exp $
* $Id: netutils.c,v 1.56 2002/02/20 23:23:53 sam Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Benoit Steiner <benny@via.ecp.fr>
......@@ -51,7 +51,7 @@
#ifdef WIN32
# include <winsock2.h>
#elif !defined( SYS_BEOS ) && !defined( SYS_NTO )
#elif !defined( SYS_BEOS )
# include <netdb.h> /* hostent ... */
# include <sys/socket.h> /* BSD: struct sockaddr */
# include <netinet/in.h> /* BSD: struct in_addr */
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment