Commit b2f56af9 authored by Sam Hocevar's avatar Sam Hocevar

 * Fixed a segfault in the input thread creation, as well as a possible
   deadlock. This happened mostly when opening non-existing files.
 * Created input_SetStatus to do input_SetRate's job. input_SetRate will
   be used to set an arbitrary rate, for people who want to read DVDs at
   1/2.71828 times the actual speed.
 * Stubs for the ncurses control interface. No working code yet, but the
   holes just need to be filled.
 * Improved X11 support. Still not as functional as before.
 * The output window now states the method name, so that people know whether
   they are using X11 or SDL.
 * The Gnome interface is now drag'n'drop aware, you can drop a file
   on it just like Xine does (or so I guess).
parent 16247a75
......@@ -345,6 +345,9 @@ PLUGIN_MOTIONMMXEXT = plugins/motion/motionmmxext.o \
plugins/motion/vdec_motion_common.o \
plugins/motion/vdec_motion_inner_mmxext.o
PLUGIN_NCURSES = plugins/text/ncurses.o \
plugins/text/intf_ncurses.o
PLUGIN_NULL = plugins/null/null.o
PLUGIN_PS = plugins/mpeg/ps.o \
......@@ -385,6 +388,7 @@ STD_PLUGIN_OBJ = \
$(PLUGIN_MOTION) \
$(PLUGIN_MOTIONMMX) \
$(PLUGIN_MOTIONMMXEXT) \
$(PLUGIN_NCURSES) \
$(PLUGIN_NULL) \
$(PLUGIN_PS) \
$(PLUGIN_SDL) \
......@@ -612,6 +616,9 @@ lib/ggi.so: $(PLUGIN_GGI)
lib/sdl.so: $(PLUGIN_SDL)
$(CC) $(PCFLAGS) -shared -o $@ $^ $(LIB_SDL)
lib/ncurses.so: $(PLUGIN_NCURSES)
$(CC) $(PCFLAGS) -shared -o $@ $^ -lcurses
ifeq ($(SYS),beos)
lib/null.so: $(PLUGIN_NULL)
$(CC) -nostart -Xlinker -soname=$@ -o $@ $^ plugins/_APP_
......
......@@ -37,6 +37,8 @@ ac_help="$ac_help
--with-sdl[=name] SDL support (default enabled)"
ac_help="$ac_help
--with-glide[=name] Glide (3dfx) support (default disabled)"
ac_help="$ac_help
--enable-ncurses ncurses interface support (default disabled)"
ac_help="$ac_help
--disable-gnome Gnome support (default enabled)"
ac_help="$ac_help
......@@ -581,7 +583,7 @@ else { echo "configure: error: can not run $ac_config_sub" 1>&2; exit 1; }
fi
echo $ac_n "checking host system type""... $ac_c" 1>&6
echo "configure:585: checking host system type" >&5
echo "configure:587: checking host system type" >&5
host_alias=$host
case "$host_alias" in
......@@ -608,7 +610,7 @@ VLC_CODENAME=Urumov
echo $ac_n "checking whether ${MAKE-make} sets \${MAKE}""... $ac_c" 1>&6
echo "configure:612: checking whether ${MAKE-make} sets \${MAKE}" >&5
echo "configure:614: checking whether ${MAKE-make} sets \${MAKE}" >&5
set dummy ${MAKE-make}; ac_make=`echo "$2" | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_prog_make_${ac_make}_set'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -638,7 +640,7 @@ if test -z "$CC"; then
# Extract the first word of "gcc", so it can be a program name with args.
set dummy gcc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:642: checking for $ac_word" >&5
echo "configure:644: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -668,7 +670,7 @@ if test -z "$CC"; then
# Extract the first word of "cc", so it can be a program name with args.
set dummy cc; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:672: checking for $ac_word" >&5
echo "configure:674: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -719,7 +721,7 @@ fi
# Extract the first word of "cl", so it can be a program name with args.
set dummy cl; ac_word=$2
echo $ac_n "checking for $ac_word""... $ac_c" 1>&6
echo "configure:723: checking for $ac_word" >&5
echo "configure:725: checking for $ac_word" >&5
if eval "test \"`echo '$''{'ac_cv_prog_CC'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -751,7 +753,7 @@ fi
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works""... $ac_c" 1>&6
echo "configure:755: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
echo "configure:757: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) works" >&5
ac_ext=c
# CFLAGS is not in ac_cpp because -g, -O, etc. are not valid cpp options.
......@@ -762,12 +764,12 @@ cross_compiling=$ac_cv_prog_cc_cross
cat > conftest.$ac_ext << EOF
#line 766 "configure"
#line 768 "configure"
#include "confdefs.h"
main(){return(0);}
EOF
if { (eval echo configure:771: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:773: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
ac_cv_prog_cc_works=yes
# If we can't run a trivial program, we are probably using a cross compiler.
if (./conftest; exit) 2>/dev/null; then
......@@ -793,12 +795,12 @@ if test $ac_cv_prog_cc_works = no; then
{ echo "configure: error: installation or configuration problem: C compiler cannot create executables." 1>&2; exit 1; }
fi
echo $ac_n "checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler""... $ac_c" 1>&6
echo "configure:797: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "configure:799: checking whether the C compiler ($CC $CFLAGS $LDFLAGS) is a cross-compiler" >&5
echo "$ac_t""$ac_cv_prog_cc_cross" 1>&6
cross_compiling=$ac_cv_prog_cc_cross
echo $ac_n "checking whether we are using GNU C""... $ac_c" 1>&6
echo "configure:802: checking whether we are using GNU C" >&5
echo "configure:804: checking whether we are using GNU C" >&5
if eval "test \"`echo '$''{'ac_cv_prog_gcc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -807,7 +809,7 @@ else
yes;
#endif
EOF
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:811: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
if { ac_try='${CC-cc} -E conftest.c'; { (eval echo configure:813: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }; } | egrep yes >/dev/null 2>&1; then
ac_cv_prog_gcc=yes
else
ac_cv_prog_gcc=no
......@@ -826,7 +828,7 @@ ac_test_CFLAGS="${CFLAGS+set}"
ac_save_CFLAGS="$CFLAGS"
CFLAGS=
echo $ac_n "checking whether ${CC-cc} accepts -g""... $ac_c" 1>&6
echo "configure:830: checking whether ${CC-cc} accepts -g" >&5
echo "configure:832: checking whether ${CC-cc} accepts -g" >&5
if eval "test \"`echo '$''{'ac_cv_prog_cc_g'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -860,7 +862,7 @@ fi
fi
if test -z "$CPP"; then
echo $ac_n "checking how to run the C preprocessor""... $ac_c" 1>&6
echo "configure:864: checking how to run the C preprocessor" >&5
echo "configure:866: checking how to run the C preprocessor" >&5
# On Suns, sometimes $CPP names a directory.
if test -n "$CPP" && test -d "$CPP"; then
CPP=
......@@ -875,13 +877,13 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp.
cat > conftest.$ac_ext <<EOF
#line 879 "configure"
#line 881 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:885: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:887: \"$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
:
......@@ -892,13 +894,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF
#line 896 "configure"
#line 898 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:902: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:904: \"$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
:
......@@ -909,13 +911,13 @@ else
rm -rf conftest*
CPP="${CC-cc} -nologo -E"
cat > conftest.$ac_ext <<EOF
#line 913 "configure"
#line 915 "configure"
#include "confdefs.h"
#include <assert.h>
Syntax Error
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:919: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:921: \"$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
:
......@@ -953,7 +955,7 @@ fi
# SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff"
# ./install, which can be erroneously created by make from ./install.sh.
echo $ac_n "checking for a BSD compatible install""... $ac_c" 1>&6
echo "configure:957: checking for a BSD compatible install" >&5
echo "configure:959: checking for a BSD compatible install" >&5
if test -z "$INSTALL"; then
if eval "test \"`echo '$''{'ac_cv_path_install'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1007,12 +1009,12 @@ test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644'
echo $ac_n "checking for working const""... $ac_c" 1>&6
echo "configure:1011: checking for working const" >&5
echo "configure:1013: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1016 "configure"
#line 1018 "configure"
#include "confdefs.h"
int main() {
......@@ -1061,7 +1063,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
if { (eval echo configure:1065: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1067: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
......@@ -1082,14 +1084,14 @@ EOF
fi
echo $ac_n "checking whether byte ordering is bigendian""... $ac_c" 1>&6
echo "configure:1086: checking whether byte ordering is bigendian" >&5
echo "configure:1088: checking whether byte ordering is bigendian" >&5
if eval "test \"`echo '$''{'ac_cv_c_bigendian'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
ac_cv_c_bigendian=unknown
# See if sys/param.h defines the BYTE_ORDER macro.
cat > conftest.$ac_ext <<EOF
#line 1093 "configure"
#line 1095 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
......@@ -1100,11 +1102,11 @@ int main() {
#endif
; return 0; }
EOF
if { (eval echo configure:1104: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1106: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
# It does; now see whether it defined to BIG_ENDIAN or not.
cat > conftest.$ac_ext <<EOF
#line 1108 "configure"
#line 1110 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/param.h>
......@@ -1115,7 +1117,7 @@ int main() {
#endif
; return 0; }
EOF
if { (eval echo configure:1119: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1121: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_bigendian=yes
else
......@@ -1135,7 +1137,7 @@ if test "$cross_compiling" = yes; then
{ echo "configure: error: can not run test program while cross compiling" 1>&2; exit 1; }
else
cat > conftest.$ac_ext <<EOF
#line 1139 "configure"
#line 1141 "configure"
#include "confdefs.h"
main () {
/* Are we little or big endian? From Harbison&Steele. */
......@@ -1148,7 +1150,7 @@ main () {
exit (u.c[sizeof (long) - 1] == 1);
}
EOF
if { (eval echo configure:1152: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
if { (eval echo configure:1154: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_c_bigendian=no
else
......@@ -1173,9 +1175,9 @@ fi
echo $ac_n "checking whether compiler accepts bswap x86 instruction""... $ac_c" 1>&6
echo "configure:1177: checking whether compiler accepts bswap x86 instruction" >&5
echo "configure:1179: checking whether compiler accepts bswap x86 instruction" >&5
cat > conftest.$ac_ext <<EOF
#line 1179 "configure"
#line 1181 "configure"
#include "confdefs.h"
unsigned int foo( unsigned int x )
{ __asm__("bswap %0" : "=r" (x) : "0" (x)); return x; }
......@@ -1183,7 +1185,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:1187: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:1189: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
#define HAVE_X86_BSWAP 1
......@@ -1200,12 +1202,12 @@ rm -f conftest*
for ac_func in gettimeofday select strerror strtod strtol
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:1204: checking for $ac_func" >&5
echo "configure:1206: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1209 "configure"
#line 1211 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
......@@ -1228,7 +1230,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:1232: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1234: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
......@@ -1255,12 +1257,12 @@ done
for ac_func in setenv putenv
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:1259: checking for $ac_func" >&5
echo "configure:1261: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1264 "configure"
#line 1266 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
......@@ -1283,7 +1285,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:1287: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1289: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
......@@ -1308,12 +1310,12 @@ fi
done
echo $ac_n "checking for connect""... $ac_c" 1>&6
echo "configure:1312: checking for connect" >&5
echo "configure:1314: checking for connect" >&5
if eval "test \"`echo '$''{'ac_cv_func_connect'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1317 "configure"
#line 1319 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char connect(); below. */
......@@ -1336,7 +1338,7 @@ connect();
; return 0; }
EOF
if { (eval echo configure:1340: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1342: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_connect=yes"
else
......@@ -1354,7 +1356,7 @@ if eval "test \"`echo '$ac_cv_func_'connect`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for connect in -lsocket""... $ac_c" 1>&6
echo "configure:1358: checking for connect in -lsocket" >&5
echo "configure:1360: checking for connect in -lsocket" >&5
ac_lib_var=`echo socket'_'connect | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1362,7 +1364,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1366 "configure"
#line 1368 "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
......@@ -1373,7 +1375,7 @@ int main() {
connect()
; return 0; }
EOF
if { (eval echo configure:1377: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1379: \"$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
......@@ -1403,12 +1405,12 @@ fi
fi
echo $ac_n "checking for gethostbyname""... $ac_c" 1>&6
echo "configure:1407: checking for gethostbyname" >&5
echo "configure:1409: checking for gethostbyname" >&5
if eval "test \"`echo '$''{'ac_cv_func_gethostbyname'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1412 "configure"
#line 1414 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char gethostbyname(); below. */
......@@ -1431,7 +1433,7 @@ gethostbyname();
; return 0; }
EOF
if { (eval echo configure:1435: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1437: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_gethostbyname=yes"
else
......@@ -1449,7 +1451,7 @@ if eval "test \"`echo '$ac_cv_func_'gethostbyname`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for gethostbyname in -lnsl""... $ac_c" 1>&6
echo "configure:1453: checking for gethostbyname in -lnsl" >&5
echo "configure:1455: checking for gethostbyname in -lnsl" >&5
ac_lib_var=`echo nsl'_'gethostbyname | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1457,7 +1459,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1461 "configure"
#line 1463 "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
......@@ -1468,7 +1470,7 @@ int main() {
gethostbyname()
; return 0; }
EOF
if { (eval echo configure:1472: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1474: \"$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
......@@ -1498,12 +1500,12 @@ fi
fi
echo $ac_n "checking for nanosleep""... $ac_c" 1>&6
echo "configure:1502: checking for nanosleep" >&5
echo "configure:1504: checking for nanosleep" >&5
if eval "test \"`echo '$''{'ac_cv_func_nanosleep'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1507 "configure"
#line 1509 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char nanosleep(); below. */
......@@ -1526,7 +1528,7 @@ nanosleep();
; return 0; }
EOF
if { (eval echo configure:1530: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1532: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_nanosleep=yes"
else
......@@ -1544,7 +1546,7 @@ if eval "test \"`echo '$ac_cv_func_'nanosleep`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for nanosleep in -lrt""... $ac_c" 1>&6
echo "configure:1548: checking for nanosleep in -lrt" >&5
echo "configure:1550: checking for nanosleep in -lrt" >&5
ac_lib_var=`echo rt'_'nanosleep | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1552,7 +1554,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lrt $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1556 "configure"
#line 1558 "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
......@@ -1563,7 +1565,7 @@ int main() {
nanosleep()
; return 0; }
EOF
if { (eval echo configure:1567: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1569: \"$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
......@@ -1589,7 +1591,7 @@ EOF
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for nanosleep in -lposix4""... $ac_c" 1>&6
echo "configure:1593: checking for nanosleep in -lposix4" >&5
echo "configure:1595: checking for nanosleep in -lposix4" >&5
ac_lib_var=`echo posix4'_'nanosleep | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1597,7 +1599,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lposix4 $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1601 "configure"
#line 1603 "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
......@@ -1608,7 +1610,7 @@ int main() {
nanosleep()
; return 0; }
EOF
if { (eval echo configure:1612: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1614: \"$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
......@@ -1642,12 +1644,12 @@ fi
for ac_func in usleep
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:1646: checking for $ac_func" >&5
echo "configure:1648: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1651 "configure"
#line 1653 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
......@@ -1670,7 +1672,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:1674: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1676: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
......@@ -1695,12 +1697,12 @@ fi
done
echo $ac_n "checking for inet_aton""... $ac_c" 1>&6
echo "configure:1699: checking for inet_aton" >&5
echo "configure:1701: checking for inet_aton" >&5
if eval "test \"`echo '$''{'ac_cv_func_inet_aton'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1704 "configure"
#line 1706 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char inet_aton(); below. */
......@@ -1723,7 +1725,7 @@ inet_aton();
; return 0; }
EOF
if { (eval echo configure:1727: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1729: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_inet_aton=yes"
else
......@@ -1741,7 +1743,7 @@ if eval "test \"`echo '$ac_cv_func_'inet_aton`\" = yes"; then
else
echo "$ac_t""no" 1>&6
echo $ac_n "checking for inet_aton in -lresolv""... $ac_c" 1>&6
echo "configure:1745: checking for inet_aton in -lresolv" >&5
echo "configure:1747: checking for inet_aton in -lresolv" >&5
ac_lib_var=`echo resolv'_'inet_aton | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -1749,7 +1751,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lresolv $LIBS"
cat > conftest.$ac_ext <<EOF
#line 1753 "configure"
#line 1755 "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
......@@ -1760,7 +1762,7 @@ int main() {
inet_aton()
; return 0; }
EOF
if { (eval echo configure:1764: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1766: \"$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
......@@ -1792,12 +1794,12 @@ fi
for ac_func in vasprintf
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:1796: checking for $ac_func" >&5
echo "configure:1798: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1801 "configure"
#line 1803 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
......@@ -1820,7 +1822,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:1824: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1826: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
......@@ -1848,17 +1850,17 @@ for ac_hdr in unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:1852: checking for $ac_hdr" >&5
echo "configure:1854: 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 1857 "configure"
#line 1859 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:1862: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:1864: \"$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*
......@@ -1887,12 +1889,12 @@ done
for ac_func in getpagesize
do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
echo "configure:1891: checking for $ac_func" >&5
echo "configure:1893: checking for $ac_func" >&5
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 1896 "configure"
#line 1898 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
......@@ -1915,7 +1917,7 @@ $ac_func();
; return 0; }
EOF
if { (eval echo configure:1919: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:1921: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_$ac_func=yes"
else
......@@ -1940,7 +1942,7 @@ fi
done
echo $ac_n "checking for working mmap""... $ac_c" 1>&6
echo "configure:1944: checking for working mmap" >&5
echo "configure:1946: checking for working mmap" >&5
if eval "test \"`echo '$''{'ac_cv_func_mmap_fixed_mapped'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
......@@ -1948,7 +1950,7 @@ else
ac_cv_func_mmap_fixed_mapped=no
else
cat > conftest.$ac_ext <<EOF
#line 1952 "configure"
#line 1954 "configure"
#include "confdefs.h"
/* Thanks to Mike Haertel and Jim Avera for this test.
......@@ -2088,7 +2090,7 @@ main()
}
EOF
if { (eval echo configure:2092: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
if { (eval echo configure:2094: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
ac_cv_func_mmap_fixed_mapped=yes
else
......@@ -2111,12 +2113,12 @@ EOF
fi
echo $ac_n "checking return type of signal handlers""... $ac_c" 1>&6
echo "configure:2115: checking return type of signal handlers" >&5
echo "configure:2117: checking return type of signal handlers" >&5
if eval "test \"`echo '$''{'ac_cv_type_signal'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2120 "configure"
#line 2122 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <signal.h>
......@@ -2133,7 +2135,7 @@ int main() {
int i;
; return 0; }
EOF
if { (eval echo configure:2137: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:2139: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_type_signal=void
else
......@@ -2152,7 +2154,7 @@ EOF
echo $ac_n "checking for dlopen in -ldl""... $ac_c" 1>&6
echo "configure:2156: checking for dlopen in -ldl" >&5
echo "configure:2158: checking for dlopen in -ldl" >&5
ac_lib_var=`echo dl'_'dlopen | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2160,7 +2162,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-ldl $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2164 "configure"
#line 2166 "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
......@@ -2171,7 +2173,7 @@ int main() {
dlopen()
; return 0; }
EOF
if { (eval echo configure:2175: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2177: \"$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
......@@ -2199,7 +2201,7 @@ else
fi
echo $ac_n "checking for optarg in -lgnugetopt""... $ac_c" 1>&6
echo "configure:2203: checking for optarg in -lgnugetopt" >&5
echo "configure:2205: checking for optarg in -lgnugetopt" >&5
ac_lib_var=`echo gnugetopt'_'optarg | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2207,7 +2209,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lgnugetopt $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2211 "configure"
#line 2213 "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
......@@ -2218,7 +2220,7 @@ int main() {
optarg()
; return 0; }
EOF
if { (eval echo configure:2222: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2224: \"$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
......@@ -2246,7 +2248,7 @@ else
fi
echo $ac_n "checking for _ in -lbe""... $ac_c" 1>&6
echo "configure:2250: checking for _ in -lbe" >&5
echo "configure:2252: checking for _ in -lbe" >&5
ac_lib_var=`echo be'_'_ | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2254,7 +2256,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lbe $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2258 "configure"
#line 2260 "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
......@@ -2265,7 +2267,7 @@ int main() {
_()
; return 0; }
EOF
if { (eval echo configure:2269: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2271: \"$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
......@@ -2293,7 +2295,7 @@ else
fi
echo $ac_n "checking for _ in -lgame""... $ac_c" 1>&6
echo "configure:2297: checking for _ in -lgame" >&5
echo "configure:2299: checking for _ in -lgame" >&5
ac_lib_var=`echo game'_'_ | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2301,7 +2303,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lgame $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2305 "configure"
#line 2307 "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
......@@ -2312,7 +2314,7 @@ int main() {
_()
; return 0; }
EOF
if { (eval echo configure:2316: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2318: \"$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
......@@ -2340,7 +2342,7 @@ else
fi
echo $ac_n "checking for _ in -lroot""... $ac_c" 1>&6
echo "configure:2344: checking for _ in -lroot" >&5
echo "configure:2346: checking for _ in -lroot" >&5
ac_lib_var=`echo root'_'_ | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2348,7 +2350,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lroot $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2352 "configure"
#line 2354 "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
......@@ -2359,7 +2361,7 @@ int main() {
_()
; return 0; }
EOF
if { (eval echo configure:2363: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2365: \"$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
......@@ -2387,7 +2389,7 @@ else
fi
echo $ac_n "checking for powl in -lm""... $ac_c" 1>&6
echo "configure:2391: checking for powl in -lm" >&5
echo "configure:2393: checking for powl in -lm" >&5
ac_lib_var=`echo m'_'powl | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2395,7 +2397,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lm $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2399 "configure"
#line 2401 "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
......@@ -2406,7 +2408,7 @@ int main() {
powl()
; return 0; }
EOF
if { (eval echo configure:2410: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2412: \"$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
......@@ -2434,7 +2436,7 @@ else
fi
echo $ac_n "checking for pthread_create in -lpthread""... $ac_c" 1>&6
echo "configure:2438: checking for pthread_create in -lpthread" >&5
echo "configure:2440: checking for pthread_create in -lpthread" >&5
ac_lib_var=`echo pthread'_'pthread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2442,7 +2444,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lpthread $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2446 "configure"
#line 2448 "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
......@@ -2453,7 +2455,7 @@ int main() {
pthread_create()
; return 0; }
EOF
if { (eval echo configure:2457: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2459: \"$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
......@@ -2481,7 +2483,7 @@ else
fi
echo $ac_n "checking for thread_create in -lthreads""... $ac_c" 1>&6
echo "configure:2485: checking for thread_create in -lthreads" >&5
echo "configure:2487: checking for thread_create in -lthreads" >&5
ac_lib_var=`echo threads'_'thread_create | sed 'y%./+-%__p_%'`
if eval "test \"`echo '$''{'ac_cv_lib_$ac_lib_var'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
......@@ -2489,7 +2491,7 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lthreads $LIBS"
cat > conftest.$ac_ext <<EOF
#line 2493 "configure"
#line 2495 "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
......@@ -2500,7 +2502,7 @@ int main() {
thread_create()
; return 0; }
EOF
if { (eval echo configure:2504: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2506: \"$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
......@@ -2529,12 +2531,12 @@ fi
echo $ac_n "checking for getopt_long""... $ac_c" 1>&6
echo "configure:2533: checking for getopt_long" >&5
echo "configure:2535: checking for getopt_long" >&5
if eval "test \"`echo '$''{'ac_cv_func_getopt_long'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 2538 "configure"
#line 2540 "configure"
#include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char getopt_long(); below. */
......@@ -2557,7 +2559,7 @@ getopt_long();
; return 0; }
EOF
if { (eval echo configure:2561: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:2563: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
rm -rf conftest*
eval "ac_cv_func_getopt_long=yes"
else
......@@ -2584,17 +2586,17 @@ for ac_hdr in stddef.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2588: checking for $ac_hdr" >&5
echo "configure:2590: 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 2593 "configure"
#line 2595 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2598: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2600: \"$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*
......@@ -2624,17 +2626,17 @@ for ac_hdr in getopt.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2628: checking for $ac_hdr" >&5
echo "configure:2630: 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 2633 "configure"
#line 2635 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2638: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2640: \"$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*
......@@ -2664,17 +2666,17 @@ for ac_hdr in sys/sockio.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2668: checking for $ac_hdr" >&5
echo "configure:2670: 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 2673 "configure"
#line 2675 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2678: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2680: \"$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*
......@@ -2704,17 +2706,17 @@ for ac_hdr in fcntl.h sys/ioctl.h sys/time.h unistd.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2708: checking for $ac_hdr" >&5
echo "configure:2710: 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 2713 "configure"
#line 2715 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2718: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2720: \"$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*
......@@ -2744,17 +2746,17 @@ for ac_hdr in sys/soundcard.h machine/soundcard.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2748: checking for $ac_hdr" >&5
echo "configure:2750: 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 2753 "configure"
#line 2755 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2758: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2760: \"$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*
......@@ -2784,17 +2786,17 @@ for ac_hdr in dlfcn.h image.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2788: checking for $ac_hdr" >&5
echo "configure:2790: 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 2793 "configure"
#line 2795 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2798: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2800: \"$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*
......@@ -2824,17 +2826,17 @@ for ac_hdr in arpa/inet.h net/if.h netinet/in.h sys/socket.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2828: checking for $ac_hdr" >&5
echo "configure:2830: 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 2833 "configure"
#line 2835 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2838: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2840: \"$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*
......@@ -2864,17 +2866,17 @@ for ac_hdr in machine/param.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2868: checking for $ac_hdr" >&5
echo "configure:2870: 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 2873 "configure"
#line 2875 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2878: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2880: \"$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*
......@@ -2905,17 +2907,17 @@ for ac_hdr in cthreads.h pthread.h kernel/scheduler.h kernel/OS.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:2909: checking for $ac_hdr" >&5
echo "configure:2911: 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 2914 "configure"
#line 2916 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:2919: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:2921: \"$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*
......@@ -2946,9 +2948,9 @@ save_CFLAGS=$CFLAGS
CFLAGS="${CFLAGS} -Wall -Werror"
echo $ac_n "checking for ntohl in sys/param.h""... $ac_c" 1>&6
echo "configure:2950: checking for ntohl in sys/param.h" >&5
echo "configure:2952: checking for ntohl in sys/param.h" >&5
cat > conftest.$ac_ext <<EOF
#line 2952 "configure"
#line 2954 "configure"
#include "confdefs.h"
#include <sys/param.h>
void foo() { int meuh; ntohl(meuh); }
......@@ -2956,7 +2958,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:2960: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:2962: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
#define NTOHL_IN_SYS_PARAM_H 1
......@@ -2973,16 +2975,16 @@ rm -f conftest*
CFLAGS="${CFLAGS} -rdynamic"
echo $ac_n "checking if \$CC accepts -rdynamic""... $ac_c" 1>&6
echo "configure:2977: checking if \$CC accepts -rdynamic" >&5
echo "configure:2979: checking if \$CC accepts -rdynamic" >&5
cat > conftest.$ac_ext <<EOF
#line 2979 "configure"
#line 2981 "configure"
#include "confdefs.h"
int main() {
; return 0; }
EOF
if { (eval echo configure:2986: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:2988: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
DYNAMIC_FLAG="-rdynamic"
echo "$ac_t""yes" 1>&6
......@@ -2997,9 +2999,9 @@ rm -f conftest*
CFLAGS=$save_CFLAGS
echo $ac_n "checking for boolean_t in sys/types.h""... $ac_c" 1>&6
echo "configure:3001: checking for boolean_t in sys/types.h" >&5
echo "configure:3003: checking for boolean_t in sys/types.h" >&5
cat > conftest.$ac_ext <<EOF
#line 3003 "configure"
#line 3005 "configure"
#include "confdefs.h"
#include <sys/types.h>
void quux() { boolean_t foo; }
......@@ -3007,7 +3009,7 @@ int main() {
; return 0; }
EOF
if { (eval echo configure:3011: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:3013: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
cat >> confdefs.h <<\EOF
#define BOOLEAN_T_IN_SYS_TYPES_H 1
......@@ -3023,12 +3025,12 @@ fi
rm -f conftest*
echo $ac_n "checking for working const""... $ac_c" 1>&6
echo "configure:3027: checking for working const" >&5
echo "configure:3029: checking for working const" >&5
if eval "test \"`echo '$''{'ac_cv_c_const'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 3032 "configure"
#line 3034 "configure"
#include "confdefs.h"
int main() {
......@@ -3077,7 +3079,7 @@ ccp = (char const *const *) p;
; return 0; }
EOF
if { (eval echo configure:3081: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:3083: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_c_const=yes
else
......@@ -3098,12 +3100,12 @@ EOF
fi
echo $ac_n "checking for ANSI C header files""... $ac_c" 1>&6
echo "configure:3102: checking for ANSI C header files" >&5
echo "configure:3104: checking for ANSI C header files" >&5
if eval "test \"`echo '$''{'ac_cv_header_stdc'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 3107 "configure"
#line 3109 "configure"
#include "confdefs.h"
#include <stdlib.h>
#include <stdarg.h>
......@@ -3111,7 +3113,7 @@ else
#include <float.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:3115: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:3117: \"$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*
......@@ -3128,7 +3130,7 @@ rm -f conftest*
if test $ac_cv_header_stdc = yes; then
# SunOS 4.x string.h does not declare mem*, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 3132 "configure"
#line 3134 "configure"
#include "confdefs.h"
#include <string.h>
EOF
......@@ -3146,7 +3148,7 @@ fi
if test $ac_cv_header_stdc = yes; then
# ISC 2.0.2 stdlib.h does not declare free, contrary to ANSI.
cat > conftest.$ac_ext <<EOF
#line 3150 "configure"
#line 3152 "configure"
#include "confdefs.h"
#include <stdlib.h>
EOF
......@@ -3167,7 +3169,7 @@ if test "$cross_compiling" = yes; then
:
else
cat > conftest.$ac_ext <<EOF
#line 3171 "configure"
#line 3173 "configure"
#include "confdefs.h"
#include <ctype.h>
#define ISLOWER(c) ('a' <= (c) && (c) <= 'z')
......@@ -3178,7 +3180,7 @@ if (XOR (islower (i), ISLOWER (i)) || toupper (i) != TOUPPER (i)) exit(2);
exit (0); }
EOF
if { (eval echo configure:3182: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
if { (eval echo configure:3184: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext} && (./conftest; exit) 2>/dev/null
then
:
else
......@@ -3202,12 +3204,12 @@ EOF
fi
echo $ac_n "checking for size_t""... $ac_c" 1>&6
echo "configure:3206: checking for size_t" >&5
echo "configure:3208: checking for size_t" >&5
if eval "test \"`echo '$''{'ac_cv_type_size_t'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 3211 "configure"
#line 3213 "configure"
#include "confdefs.h"
#include <sys/types.h>
#if STDC_HEADERS
......@@ -3235,12 +3237,12 @@ EOF
fi
echo $ac_n "checking whether time.h and sys/time.h may both be included""... $ac_c" 1>&6
echo "configure:3239: checking whether time.h and sys/time.h may both be included" >&5
echo "configure:3241: checking whether time.h and sys/time.h may both be included" >&5
if eval "test \"`echo '$''{'ac_cv_header_time'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6
else
cat > conftest.$ac_ext <<EOF
#line 3244 "configure"
#line 3246 "configure"
#include "confdefs.h"
#include <sys/types.h>
#include <sys/time.h>
......@@ -3249,7 +3251,7 @@ int main() {
struct tm *tp;
; return 0; }
EOF
if { (eval echo configure:3253: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
if { (eval echo configure:3255: \"$ac_compile\") 1>&5; (eval $ac_compile) 2>&5; }; then
rm -rf conftest*
ac_cv_header_time=yes
else
......@@ -3274,17 +3276,17 @@ for ac_hdr in sys/ioctl.h
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:3278: checking for $ac_hdr" >&5
echo "configure:3280: 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 3283 "configure"
#line 3285 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:3288: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:3290: \"$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*
......@@ -3308,17 +3310,17 @@ EOF
do
ac_safe=`echo "$ac_hdr" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for $ac_hdr""... $ac_c" 1>&6
echo "configure:3312: checking for $ac_hdr" >&5
echo "configure:3314: 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 3317 "configure"
#line 3319 "configure"
#include "confdefs.h"
#include <$ac_hdr>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:3322: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:3324: \"$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*
......@@ -3345,7 +3347,7 @@ fi
done
cat > conftest.$ac_ext <<EOF
#line 3349 "configure"
#line 3351 "configure"
#include "confdefs.h"
#include <linux/cdrom.h>
EOF
......@@ -3487,6 +3489,12 @@ if test "${with_glide+set}" = set; then
fi
fi
# Check whether --enable-ncurses or --disable-ncurses was given.
if test "${enable_ncurses+set}" = set; then
enableval="$enable_ncurses"
if test x$enable_ncurses = xyes; then PLUGINS=${PLUGINS}"ncurses "; fi
fi
# Check whether --enable-gnome or --disable-gnome was given.
if test "${enable_gnome+set}" = set; then
enableval="$enable_gnome"
......@@ -3507,17 +3515,17 @@ if test "${enable_alsa+set}" = set; then
enableval="$enable_alsa"
if test x$enable_alsa = xyes; then ac_safe=`echo "sys/asoundlib.h" | sed 'y%./+-%__p_%'`
echo $ac_n "checking for sys/asoundlib.h""... $ac_c" 1>&6
echo "configure:3511: checking for sys/asoundlib.h" >&5
echo "configure:3519: checking for sys/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 3516 "configure"
#line 3524 "configure"
#include "confdefs.h"
#include <sys/asoundlib.h>
EOF
ac_try="$ac_cpp conftest.$ac_ext >/dev/null 2>conftest.out"
{ (eval echo configure:3521: \"$ac_try\") 1>&5; (eval $ac_try) 2>&5; }
{ (eval echo configure:3529: \"$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*
......@@ -3534,7 +3542,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:3538: checking for main in -lasound" >&5
echo "configure:3546: 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
......@@ -3542,14 +3550,14 @@ else
ac_save_LIBS="$LIBS"
LIBS="-lasound $LIBS"
cat > conftest.$ac_ext <<EOF
#line 3546 "configure"
#line 3554 "configure"
#include "confdefs.h"
int main() {
main()
; return 0; }
EOF
if { (eval echo configure:3553: \"$ac_link\") 1>&5; (eval $ac_link) 2>&5; } && test -s conftest${ac_exeext}; then
if { (eval echo configure:3561: \"$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
......
......@@ -184,6 +184,9 @@ AC_ARG_WITH(glide,
else
LIB_GLIDE="-lglide2x"
fi ])
AC_ARG_ENABLE(ncurses,
[ --enable-ncurses ncurses interface support (default disabled)],
[if test x$enable_ncurses = xyes; then PLUGINS=${PLUGINS}"ncurses "; fi])
AC_ARG_ENABLE(gnome,
[ --disable-gnome Gnome support (default enabled)])
if test x$enable_gnome != xno; then PLUGINS=${PLUGINS}"gnome "; ALIASES=${ALIASES}"gvlc "; fi
......
......@@ -149,13 +149,6 @@
/* Maximum number of channels */
#define INTF_MAX_CHANNELS 10
/*
* X11 settings
*/
/* Title of the X11 window */
#define VOUT_TITLE "VideoLAN Client"
/*****************************************************************************
* Input thread configuration
*****************************************************************************/
......@@ -382,6 +375,7 @@
*/
// #define FB_NOYPAN
#define VOUT_TITLE "VideoLAN Client @VLC_VERSION@"
/*****************************************************************************
* Video parser configuration
......
......@@ -4,7 +4,7 @@
* control the pace of reading.
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: input_ext-intf.h,v 1.19 2001/02/12 09:39:15 sam Exp $
* $Id: input_ext-intf.h,v 1.20 2001/02/16 06:37:09 sam Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
*
......@@ -294,11 +294,12 @@ typedef struct input_config_s
#define INPUT_METHOD_BCAST 22 /* UDP broadcast */
#define INPUT_METHOD_VLAN_BCAST 32 /* UDP broadcast with VLANs */
/* Rate changing methods */
#define INPUT_RATE_PLAY 0
#define INPUT_RATE_PAUSE 1
#define INPUT_RATE_FASTER 2
#define INPUT_RATE_SLOWER 3
/* Status changing methods */
#define INPUT_STATUS_END 0
#define INPUT_STATUS_PLAY 1
#define INPUT_STATUS_PAUSE 2
#define INPUT_STATUS_FASTER 3
#define INPUT_STATUS_SLOWER 4
/*****************************************************************************
* Prototypes
......@@ -307,6 +308,7 @@ struct input_thread_s * input_CreateThread ( struct playlist_item_s *,
int *pi_status );
void input_DestroyThread( struct input_thread_s *, int *pi_status );
void input_SetRate( struct input_thread_s *, int );
void input_SetStatus( struct input_thread_s *, int );
void input_SetRate ( struct input_thread_s *, int );
void input_Seek ( struct input_thread_s *, off_t );
......@@ -37,6 +37,7 @@
#include "interface.h"
#include "intf_plst.h"
#include "intf_msg.h"
#include "gnome_sys.h"
#include "gnome_callbacks.h"
......@@ -171,7 +172,7 @@ on_toolbar_play_clicked (GtkButton *button,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_PLAY );
input_SetStatus( p_intf->p_input, INPUT_STATUS_PLAY );
}
}
......@@ -184,7 +185,7 @@ on_toolbar_pause_clicked (GtkButton *button,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_PAUSE );
input_SetStatus( p_intf->p_input, INPUT_STATUS_PAUSE );
}
}
......@@ -244,7 +245,7 @@ on_popup_play_activate (GtkMenuItem *menuitem,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_PLAY );
input_SetStatus( p_intf->p_input, INPUT_STATUS_PLAY );
}
}
......@@ -257,7 +258,7 @@ on_popup_pause_activate (GtkMenuItem *menuitem,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_PAUSE );
input_SetStatus( p_intf->p_input, INPUT_STATUS_PAUSE );
}
}
......@@ -379,7 +380,7 @@ on_popup_slow_activate (GtkMenuItem *menuitem,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_SLOWER );
input_SetStatus( p_intf->p_input, INPUT_STATUS_SLOWER );
}
}
......@@ -392,7 +393,7 @@ on_popup_fast_activate (GtkMenuItem *menuitem,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_FASTER );
input_SetStatus( p_intf->p_input, INPUT_STATUS_FASTER );
}
}
......@@ -405,7 +406,7 @@ on_toolbar_slow_clicked (GtkButton *button,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_SLOWER );
input_SetStatus( p_intf->p_input, INPUT_STATUS_SLOWER );
}
}
......@@ -418,7 +419,7 @@ on_toolbar_fast_clicked (GtkButton *button,
if( p_intf->p_input != NULL )
{
input_SetRate( p_intf->p_input, INPUT_RATE_FASTER );
input_SetStatus( p_intf->p_input, INPUT_STATUS_FASTER );
}
}
......@@ -526,3 +527,55 @@ on_menubar_modules_activate (GtkMenuItem *menuitem,
gdk_window_raise( p_intf->p_sys->p_modules->window );
}
void
on_intf_window_drag_data_received (GtkWidget *widget,
GdkDragContext *drag_context,
gint x,
gint y,
GtkSelectionData *data,
guint info,
guint time,
gpointer user_data)
{
char *psz_text = data->data;
int i_len = strlen( psz_text );
switch( info )
{
case DROP_ACCEPT_TEXT_PLAIN: /* FIXME: handle multiple files */
if( i_len < 1 )
{
return;
}
/* get rid of ' ' at the end */
*( psz_text + i_len - 1 ) = 0;
intf_WarnMsg( 1, "intf: dropped text/uri-list data `%s'", psz_text );
intf_PlstAdd( p_main->p_playlist, PLAYLIST_END, psz_text );
break;
case DROP_ACCEPT_TEXT_URI_LIST: /* FIXME: handle multiple files */
if( i_len < 2 )
{
return;
}
/* get rid of \r\n at the end */
*( psz_text + i_len - 2 ) = 0;
intf_WarnMsg( 1, "intf: dropped text/uri-list data `%s'", psz_text );
intf_PlstAdd( p_main->p_playlist, PLAYLIST_END, psz_text );
break;
default:
intf_ErrMsg( "intf error: unknown dropped type");
break;
}
}
......@@ -187,3 +187,13 @@ on_playlist_ok_clicked (GtkButton *button,
void
on_menubar_modules_activate (GtkMenuItem *menuitem,
gpointer user_data);
void
on_intf_window_drag_data_received (GtkWidget *widget,
GdkDragContext *drag_context,
gint x,
gint y,
GtkSelectionData *data,
guint info,
guint time,
gpointer user_data);
......@@ -84,8 +84,9 @@ create_intf_window (void)
GtkWidget *toolbar_next;
GtkWidget *vbox2;
GtkWidget *label6;
GtkWidget *label7;
GtkWidget *entry1;
GtkWidget *hscale;
GtkWidget *label13;
GtkWidget *appbar;
intf_window = gnome_app_new ("VideoLAN Client", _("VideoLAN Client"));
......@@ -298,7 +299,7 @@ create_intf_window (void)
gtk_widget_show (vbox2);
gnome_app_set_contents (GNOME_APP (intf_window), vbox2);
label6 = gtk_label_new (_("File name: wazaa.mpeg"));
label6 = gtk_label_new (_("File name: this part of the interface doesn't work yet.mpeg"));
gtk_widget_ref (label6);
gtk_object_set_data_full (GTK_OBJECT (intf_window), "label6", label6,
(GtkDestroyNotify) gtk_widget_unref);
......@@ -308,16 +309,13 @@ create_intf_window (void)
gtk_misc_set_alignment (GTK_MISC (label6), 0, 0.5);
gtk_misc_set_padding (GTK_MISC (label6), 5, 0);
label7 = gtk_label_new (_("File type: awesome movie"));
gtk_widget_ref (label7);
gtk_object_set_data_full (GTK_OBJECT (intf_window), "label7", label7,
entry1 = gtk_entry_new ();
gtk_widget_ref (entry1);
gtk_object_set_data_full (GTK_OBJECT (intf_window), "entry1", entry1,
(GtkDestroyNotify) gtk_widget_unref);
gtk_widget_show (label7);
gtk_box_pack_start (GTK_BOX (vbox2), label7, FALSE, FALSE, 0);
gtk_label_set_justify (GTK_LABEL (label7), GTK_JUSTIFY_LEFT);
gtk_label_set_line_wrap (GTK_LABEL (label7), TRUE);
gtk_misc_set_alignment (GTK_MISC (label7), 0, 0.5);
gtk_misc_set_padding (GTK_MISC (label7), 5, 0);
gtk_widget_show (entry1);
gtk_box_pack_start (GTK_BOX (vbox2), entry1, FALSE, FALSE, 0);
gtk_entry_set_text (GTK_ENTRY (entry1), _("Tired of boring stub messages ? Write your own exciting message here !!"));
hscale = gtk_hscale_new (GTK_ADJUSTMENT (gtk_adjustment_new (0, 0, 100, 1, 5, 1)));
gtk_widget_ref (hscale);
......@@ -328,6 +326,14 @@ create_intf_window (void)
gtk_scale_set_value_pos (GTK_SCALE (hscale), GTK_POS_BOTTOM);
gtk_range_set_update_policy (GTK_RANGE (hscale), GTK_UPDATE_DELAYED);
label13 = gtk_label_new (_("HEY ! YOU CAN DROP A FILE ON VLC TOO :-)"));
gtk_widget_ref (label13);
gtk_object_set_data_full (GTK_OBJECT (intf_window), "label13", label13,
(GtkDestroyNotify) gtk_widget_unref);
gtk_widget_show (label13);
gtk_box_pack_start (GTK_BOX (vbox2), label13, FALSE, FALSE, 0);
gtk_misc_set_padding (GTK_MISC (label13), 0, 5);
appbar = gnome_appbar_new (TRUE, TRUE, GNOME_PREFERENCES_NEVER);
gtk_widget_ref (appbar);
gtk_object_set_data_full (GTK_OBJECT (intf_window), "appbar", appbar,
......@@ -338,6 +344,9 @@ create_intf_window (void)
gtk_signal_connect (GTK_OBJECT (intf_window), "destroy",
GTK_SIGNAL_FUNC (on_intf_window_destroy),
NULL);
gtk_signal_connect (GTK_OBJECT (intf_window), "drag_data_received",
GTK_SIGNAL_FUNC (on_intf_window_drag_data_received),
NULL);
gnome_app_install_menu_hints (GNOME_APP (intf_window), menubar_uiinfo);
gtk_signal_connect (GTK_OBJECT (toolbar_open), "clicked",
GTK_SIGNAL_FUNC (on_toolbar_open_clicked),
......
......@@ -2,9 +2,9 @@
* gnome_sys.h: private Gnome interface description
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: gnome_sys.h,v 1.4 2001/02/14 07:48:18 sam Exp $
* $Id: gnome_sys.h,v 1.5 2001/02/16 06:37:09 sam Exp $
*
* Authors:
* Authors: Samuel Hocevar <sam@zoy.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -21,6 +21,12 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/
/*****************************************************************************
* drag'n'drop stuff
*****************************************************************************/
#define DROP_ACCEPT_TEXT_URI_LIST 0
#define DROP_ACCEPT_TEXT_PLAIN 1
/*****************************************************************************
* intf_sys_t: description and status of Gnome interface
*****************************************************************************/
......
......@@ -2,7 +2,7 @@
* intf_gnome.c: Gnome interface
*****************************************************************************
* Copyright (C) 1999, 2000 VideoLAN
* $Id: intf_gnome.c,v 1.12 2001/02/15 07:59:38 sam Exp $
* $Id: intf_gnome.c,v 1.13 2001/02/16 06:37:09 sam Exp $
*
* Authors:
*
......@@ -111,7 +111,7 @@ static int intf_Probe( probedata_t *p_data )
return( 999 );
}
return( 40 );
return( 100 );
}
/*****************************************************************************
......@@ -163,13 +163,25 @@ static void intf_Run( intf_thread_t *p_intf )
* give it an empty one */
char *p_args[] = { };
/* The data types we are allowed to receive */
static GtkTargetEntry target_table[] =
{
{ "text/uri-list", 0, DROP_ACCEPT_TEXT_URI_LIST },
{ "text/plain", 0, DROP_ACCEPT_TEXT_PLAIN }
};
/* Initialize Gnome */
gnome_init( p_main->psz_arg0, VERSION, 1, p_args );
/* create some useful widgets that will certainly be used */
p_intf->p_sys->p_window = create_intf_window();
p_intf->p_sys->p_window = create_intf_window( );
p_intf->p_sys->p_popup = create_intf_popup( );
/* accept file drops on the main window */
gtk_drag_dest_set( GTK_WIDGET( p_intf->p_sys->p_window ),
GTK_DEST_DEFAULT_ALL, target_table,
1, GDK_ACTION_COPY );
/* we don't create these ones yet because we perhaps won't need them */
p_intf->p_sys->p_about = NULL;
p_intf->p_sys->p_playlist = NULL;
......@@ -191,6 +203,7 @@ static void intf_Run( intf_thread_t *p_intf )
p_intf->p_sys->i_timeout = gtk_timeout_add( INTF_IDLE_SLEEP / 1000,
GnomeManage, p_intf );
/* enter gnome mode */
gtk_main();
......
......@@ -28,6 +28,11 @@
<handler>on_intf_window_destroy</handler>
<last_modification_time>Sun, 11 Feb 2001 17:41:57 GMT</last_modification_time>
</signal>
<signal>
<name>drag_data_received</name>
<handler>on_intf_window_drag_data_received</handler>
<last_modification_time>Fri, 16 Feb 2001 01:59:35 GMT</last_modification_time>
</signal>
<title>VideoLAN Client</title>
<type>GTK_WINDOW_TOPLEVEL</type>
<position>GTK_WIN_POS_NONE</position>
......@@ -376,7 +381,7 @@
<widget>
<class>GtkLabel</class>
<name>label6</name>
<label>File name: wazaa.mpeg</label>
<label>File name: this part of the interface doesn't work yet.mpeg</label>
<justify>GTK_JUSTIFY_LEFT</justify>
<wrap>False</wrap>
<xalign>0</xalign>
......@@ -391,15 +396,13 @@
</widget>
<widget>
<class>GtkLabel</class>
<name>label7</name>
<label>File type: awesome movie</label>
<justify>GTK_JUSTIFY_LEFT</justify>
<wrap>True</wrap>
<xalign>0</xalign>
<yalign>0.5</yalign>
<xpad>5</xpad>
<ypad>0</ypad>
<class>GtkEntry</class>
<name>entry1</name>
<can_focus>True</can_focus>
<editable>True</editable>
<text_visible>True</text_visible>
<text_max_length>0</text_max_length>
<text>Tired of boring stub messages ? Write your own exciting message here !!</text>
<child>
<padding>0</padding>
<expand>False</expand>
......@@ -437,6 +440,23 @@
<fill>False</fill>
</child>
</widget>
<widget>
<class>GtkLabel</class>
<name>label13</name>
<label>HEY ! YOU CAN DROP A FILE ON VLC TOO :-)</label>
<justify>GTK_JUSTIFY_CENTER</justify>
<wrap>False</wrap>
<xalign>0.5</xalign>
<yalign>0.5</yalign>
<xpad>0</xpad>
<ypad>5</ypad>
<child>
<padding>0</padding>
<expand>False</expand>
<fill>False</fill>
</child>
</widget>
</widget>
</widget>
......
......@@ -560,7 +560,8 @@ static int SDLOpenDisplay( vout_thread_t *p_vout )
else
SDL_ShowCursor( 1 );
SDL_WM_SetCaption( VOUT_TITLE , VOUT_TITLE );
SDL_WM_SetCaption( VOUT_TITLE " (SDL output)",
VOUT_TITLE " (SDL output)" );
SDL_EventState(SDL_KEYUP , SDL_IGNORE); /* ignore keys up */
SDL_EventState(SDL_MOUSEBUTTONUP, SDL_IGNORE);
......
/*****************************************************************************
* intf_ncurses.c: ncurses interface
*****************************************************************************
* Copyright (C) 2001 VideoLAN
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/
/*****************************************************************************
* Preamble
*****************************************************************************/
#include "defs.h"
#include <errno.h> /* ENOMEM */
#include <stdlib.h> /* free() */
#include <string.h> /* strerror() */
#include <stdio.h>
#include <curses.h>
#include "config.h"
#include "common.h"
#include "threads.h"
#include "mtime.h"
#include "tests.h"
#include "modules.h"
#include "stream_control.h"
#include "input_ext-intf.h"
#include "intf_msg.h"
#include "interface.h"
#include "main.h"
/*****************************************************************************
* intf_sys_t: description and status of ncurses interface
*****************************************************************************/
typedef struct intf_sys_s
{
/* special actions */
vlc_mutex_t change_lock; /* the change lock */
} intf_sys_t;
/*****************************************************************************
* Local prototypes.
*****************************************************************************/
static int intf_Probe ( probedata_t *p_data );
static int intf_Open ( intf_thread_t *p_intf );
static void intf_Close ( intf_thread_t *p_intf );
static void intf_Run ( intf_thread_t *p_intf );
/*****************************************************************************
* Functions exported as capabilities. They are declared as static so that
* we don't pollute the namespace too much.
*****************************************************************************/
void intf_getfunctions( function_list_t * p_function_list )
{
p_function_list->pf_probe = intf_Probe;
p_function_list->functions.intf.pf_open = intf_Open;
p_function_list->functions.intf.pf_close = intf_Close;
p_function_list->functions.intf.pf_run = intf_Run;
}
/*****************************************************************************
* intf_Probe: probe the interface and return a score
*****************************************************************************
* This function tries to initialize ncurses and returns a score to the
* plugin manager so that it can select the best plugin.
*****************************************************************************/
static int intf_Probe( probedata_t *p_data )
{
if( TestMethod( INTF_METHOD_VAR, "ncurses" ) )
{
return( 999 );
}
return( 40 );
}
/*****************************************************************************
* intf_Open: initialize and create window
*****************************************************************************/
static int intf_Open( intf_thread_t *p_intf )
{
/* Allocate instance and initialize some members */
p_intf->p_sys = malloc( sizeof( intf_sys_t ) );
if( p_intf->p_sys == NULL )
{
intf_ErrMsg("error: %s", strerror(ENOMEM));
return( 1 );
}
/* Initialize the curses library */
initscr();
/* Don't do NL -> CR/NL */
nonl();
/* Take input chars one at a time */
cbreak();
/* Don't echo */
noecho();
return( 0 );
}
/*****************************************************************************
* intf_Close: destroy interface window
*****************************************************************************/
static void intf_Close( intf_thread_t *p_intf )
{
/* Close the ncurses interface */
endwin();
/* Destroy structure */
free( p_intf->p_sys );
}
/*****************************************************************************
* intf_Run: ncurses thread
*****************************************************************************/
static void intf_Run( intf_thread_t *p_intf )
{
while( !p_intf->b_die )
{
p_intf->pf_manage( p_intf );
msleep( INTF_IDLE_SLEEP );
}
}
/* following functions are local */
/*****************************************************************************
* ncurses.c : NCurses plugin for vlc
*****************************************************************************
* Copyright (C) 2001 VideoLAN
*
* Authors: Samuel Hocevar <sam@zoy.org>
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation; either version 2 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111, USA.
*****************************************************************************/
#define MODULE_NAME ncurses
/*****************************************************************************
* Preamble
*****************************************************************************/
#include "defs.h"
#include <stdlib.h> /* malloc(), free() */
#include "config.h"
#include "common.h" /* boolean_t, byte_t */
#include "threads.h"
#include "mtime.h"
#include "modules.h"
#include "modules_inner.h"
/*****************************************************************************
* Building configuration tree
*****************************************************************************/
MODULE_CONFIG_START
ADD_WINDOW( "Configuration for NCurses module" )
ADD_COMMENT( "For now, the NCurses module cannot be configured" )
MODULE_CONFIG_END
/*****************************************************************************
* Capabilities defined in the other files.
******************************************************************************/
extern void intf_getfunctions( function_list_t * p_function_list );
/*****************************************************************************
* InitModule: get the module structure and configuration.
*****************************************************************************
* We have to fill psz_name, psz_longname and psz_version. These variables
* will be strdup()ed later by the main application because the module can
* be unloaded later to save memory, and we want to be able to access this
* data even after the module has been unloaded.
*****************************************************************************/
int InitModule( module_t * p_module )
{
p_module->psz_name = MODULE_STRING;
p_module->psz_longname = "ncurses interface module";
p_module->psz_version = VERSION;
p_module->i_capabilities = MODULE_CAPABILITY_NULL
| MODULE_CAPABILITY_INTF;
return( 0 );
}
/*****************************************************************************
* ActivateModule: set the module to an usable state.
*****************************************************************************
* This function fills the capability functions and the configuration
* structure. Once ActivateModule() has been called, the i_usage can
* be set to 0 and calls to NeedModule() be made to increment it. To unload
* the module, one has to wait until i_usage == 0 and call DeactivateModule().
*****************************************************************************/
int ActivateModule( module_t * p_module )
{
p_module->p_functions = malloc( sizeof( module_functions_t ) );
if( p_module->p_functions == NULL )
{
return( -1 );
}
intf_getfunctions( &p_module->p_functions->intf );
p_module->p_config = p_config;
return( 0 );
}
/*****************************************************************************
* DeactivateModule: make sure the module can be unloaded.
*****************************************************************************
* This function must only be called when i_usage == 0. If it successfully
* returns, i_usage can be set to -1 and the module unloaded. Be careful to
* lock usage_lock during the whole process.
*****************************************************************************/
int DeactivateModule( module_t * p_module )
{
free( p_module->p_functions );
return( 0 );
}
......@@ -2,7 +2,7 @@
* vout_x11.c: X11 video output display method
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: vout_x11.c,v 1.12 2001/02/15 07:59:38 sam Exp $
* $Id: vout_x11.c,v 1.13 2001/02/16 06:37:09 sam Exp $
*
* Authors: Vincent Seguin <seguin@via.ecp.fr>
* Samuel Hocevar <sam@zoy.org>
......@@ -114,7 +114,10 @@ static int vout_Manage ( struct vout_thread_s * );
static void vout_Display ( struct vout_thread_s * );
static void vout_SetPalette( struct vout_thread_s *, u16*, u16*, u16*, u16* );
static int X11CreateWindow ( vout_thread_t *p_vout );
static int X11InitDisplay ( vout_thread_t *p_vout, char *psz_display );
static int X11CreateImage ( vout_thread_t *p_vout, XImage **pp_ximage );
static void X11DestroyImage ( XImage *p_ximage );
static int X11CreateShmImage ( vout_thread_t *p_vout, XImage **pp_ximage,
......@@ -122,8 +125,6 @@ static int X11CreateShmImage ( vout_thread_t *p_vout, XImage **pp_ximage,
static void X11DestroyShmImage ( vout_thread_t *p_vout, XImage *p_ximage,
XShmSegmentInfo *p_shm_info );
static int X11CreateWindow ( vout_thread_t *p_vout );
/* local prototypes */
static void X11TogglePointer ( vout_thread_t *p_vout );
static void X11EnableScreenSaver ( vout_thread_t *p_vout );
......@@ -574,6 +575,132 @@ static void vout_SetPalette( p_vout_thread_t p_vout,
/* following functions are local */
/*****************************************************************************
* X11CreateWindow: open and set-up X11 main window
*****************************************************************************/
static int X11CreateWindow( vout_thread_t *p_vout )
{
XSizeHints xsize_hints;
XSetWindowAttributes xwindow_attributes;
XGCValues xgcvalues;
XEvent xevent;
boolean_t b_expose;
boolean_t b_configure_notify;
boolean_t b_map_notify;
/* Set main window's size */
p_vout->p_sys->i_width = main_GetIntVariable( VOUT_WIDTH_VAR,
VOUT_WIDTH_DEFAULT );
p_vout->p_sys->i_height = main_GetIntVariable( VOUT_HEIGHT_VAR,
VOUT_HEIGHT_DEFAULT );
/* Prepare window manager hints and properties */
xsize_hints.base_width = p_vout->p_sys->i_width;
xsize_hints.base_height = p_vout->p_sys->i_height;
xsize_hints.flags = PSize;
p_vout->p_sys->wm_protocols = XInternAtom( p_vout->p_sys->p_display,
"WM_PROTOCOLS", True );
p_vout->p_sys->wm_delete_window = XInternAtom( p_vout->p_sys->p_display,
"WM_DELETE_WINDOW", True );
/* Prepare window attributes */
xwindow_attributes.backing_store = Always; /* save the hidden part */
xwindow_attributes.background_pixel = WhitePixel( p_vout->p_sys->p_display,
p_vout->p_sys->i_screen );
xwindow_attributes.event_mask = ExposureMask | StructureNotifyMask;
/* Create the window and set hints - the window must receive ConfigureNotify
* events, and, until it is displayed, Expose and MapNotify events. */
p_vout->p_sys->window =
XCreateWindow( p_vout->p_sys->p_display,
DefaultRootWindow( p_vout->p_sys->p_display ),
0, 0,
p_vout->p_sys->i_width, p_vout->p_sys->i_height, 1,
0, InputOutput, 0,
CWBackingStore | CWBackPixel | CWEventMask,
&xwindow_attributes );
/* Set window manager hints and properties: size hints, command,
* window's name, and accepted protocols */
XSetWMNormalHints( p_vout->p_sys->p_display, p_vout->p_sys->window,
&xsize_hints );
XSetCommand( p_vout->p_sys->p_display, p_vout->p_sys->window,
p_main->ppsz_argv, p_main->i_argc );
XStoreName( p_vout->p_sys->p_display, p_vout->p_sys->window,
VOUT_TITLE " (X11 output)" );
if( (p_vout->p_sys->wm_protocols == None) /* use WM_DELETE_WINDOW */
|| (p_vout->p_sys->wm_delete_window == None)
|| !XSetWMProtocols( p_vout->p_sys->p_display, p_vout->p_sys->window,
&p_vout->p_sys->wm_delete_window, 1 ) )
{
/* WM_DELETE_WINDOW is not supported by window manager */
intf_Msg( "intf error: missing or bad window manager" );
}
/* Creation of a graphic context that doesn't generate a GraphicsExpose
* event when using functions like XCopyArea */
xgcvalues.graphics_exposures = False;
p_vout->p_sys->gc = XCreateGC( p_vout->p_sys->p_display,
p_vout->p_sys->window,
GCGraphicsExposures, &xgcvalues);
/* Send orders to server, and wait until window is displayed - three
* events must be received: a MapNotify event, an Expose event allowing
* drawing in the window, and a ConfigureNotify to get the window
* dimensions. Once those events have been received, only ConfigureNotify
* events need to be received. */
b_expose = 0;
b_configure_notify = 0;
b_map_notify = 0;
XMapWindow( p_vout->p_sys->p_display, p_vout->p_sys->window);
do
{
XNextEvent( p_vout->p_sys->p_display, &xevent);
if( (xevent.type == Expose)
&& (xevent.xexpose.window == p_vout->p_sys->window) )
{
b_expose = 1;
}
else if( (xevent.type == MapNotify)
&& (xevent.xmap.window == p_vout->p_sys->window) )
{
b_map_notify = 1;
}
else if( (xevent.type == ConfigureNotify)
&& (xevent.xconfigure.window == p_vout->p_sys->window) )
{
b_configure_notify = 1;
p_vout->p_sys->i_width = xevent.xconfigure.width;
p_vout->p_sys->i_height = xevent.xconfigure.height;
}
} while( !( b_expose && b_configure_notify && b_map_notify ) );
XSelectInput( p_vout->p_sys->p_display, p_vout->p_sys->window,
StructureNotifyMask | KeyPressMask | ButtonPressMask );
if( XDefaultDepth(p_vout->p_sys->p_display, p_vout->p_sys->i_screen) == 8 )
{
/* Allocate a new palette */
p_vout->p_sys->colormap =
XCreateColormap( p_vout->p_sys->p_display,
DefaultRootWindow( p_vout->p_sys->p_display ),
DefaultVisual( p_vout->p_sys->p_display,
p_vout->p_sys->i_screen ),
AllocAll );
xwindow_attributes.colormap = p_vout->p_sys->colormap;
XChangeWindowAttributes( p_vout->p_sys->p_display,
p_vout->p_sys->window,
CWColormap, &xwindow_attributes );
}
/* At this stage, the window is open, displayed, and ready to
* receive data */
return( 0 );
}
/*****************************************************************************
* X11InitDisplay: open and initialize X11 device
*****************************************************************************
......@@ -582,7 +709,7 @@ static void vout_SetPalette( p_vout_thread_t p_vout,
*****************************************************************************/
static int X11InitDisplay( vout_thread_t *p_vout, char *psz_display )
{
XPixmapFormatValues * p_xpixmap_format; /* pixmap formats */
XPixmapFormatValues * p_formats; /* pixmap formats */
XVisualInfo * p_xvisual; /* visuals informations */
XVisualInfo xvisual_template; /* visual template */
int i_count; /* array size */
......@@ -597,7 +724,8 @@ static int X11InitDisplay( vout_thread_t *p_vout, char *psz_display )
}
/* Get screen depth */
p_vout->i_screen_depth = XDefaultDepth( p_vout->p_sys->p_display, p_vout->p_sys->i_screen );
p_vout->i_screen_depth = XDefaultDepth( p_vout->p_sys->p_display,
p_vout->p_sys->i_screen );
switch( p_vout->i_screen_depth )
{
case 8:
......@@ -606,7 +734,8 @@ static int X11InitDisplay( vout_thread_t *p_vout, char *psz_display )
*/
xvisual_template.screen = p_vout->p_sys->i_screen;
xvisual_template.class = DirectColor;
p_xvisual = XGetVisualInfo( p_vout->p_sys->p_display, VisualScreenMask | VisualClassMask,
p_xvisual = XGetVisualInfo( p_vout->p_sys->p_display,
VisualScreenMask | VisualClassMask,
&xvisual_template, &i_count );
if( p_xvisual == NULL )
{
......@@ -624,7 +753,8 @@ static int X11InitDisplay( vout_thread_t *p_vout, char *psz_display )
*/
xvisual_template.screen = p_vout->p_sys->i_screen;
xvisual_template.class = TrueColor;
p_xvisual = XGetVisualInfo( p_vout->p_sys->p_display, VisualScreenMask | VisualClassMask,
p_xvisual = XGetVisualInfo( p_vout->p_sys->p_display,
VisualScreenMask | VisualClassMask,
&xvisual_template, &i_count );
if( p_xvisual == NULL )
{
......@@ -635,21 +765,23 @@ static int X11InitDisplay( vout_thread_t *p_vout, char *psz_display )
p_vout->i_green_mask = p_xvisual->green_mask;
p_vout->i_blue_mask = p_xvisual->blue_mask;
/* There is no difference yet between 3 and 4 Bpp. The only way to find
* the actual number of bytes per pixel is to list supported pixmap
* formats. */
p_xpixmap_format = XListPixmapFormats( p_vout->p_sys->p_display, &i_count );
/* Under XFree4.0, the list contains pixmap formats available through
* all video depths ; so we have to check against current depth. */
/* There is no difference yet between 3 and 4 Bpp. The only way
* to find the actual number of bytes per pixel is to list supported
* pixmap formats. */
p_formats = XListPixmapFormats( p_vout->p_sys->p_display, &i_count );
p_vout->i_bytes_per_pixel = 0;
for( ; i_count-- ; p_xpixmap_format++ )
for( ; i_count-- ; p_formats++ )
{
if( p_xpixmap_format->depth == p_vout->i_screen_depth )
/* Under XFree4.0, the list contains pixmap formats available
* through all video depths ; so we have to check against current
* depth. */
if( p_formats->depth == p_vout->i_screen_depth )
{
if( p_xpixmap_format->bits_per_pixel / 8 > p_vout->i_bytes_per_pixel )
if( p_formats->bits_per_pixel / 8
> p_vout->i_bytes_per_pixel )
{
p_vout->i_bytes_per_pixel = p_xpixmap_format->bits_per_pixel / 8;
p_vout->i_bytes_per_pixel = p_formats->bits_per_pixel / 8;
}
}
}
......@@ -699,8 +831,9 @@ static int X11CreateImage( vout_thread_t *p_vout, XImage **pp_ximage )
}
/* Create XImage */
*pp_ximage = XCreateImage( p_vout->p_sys->p_display, p_vout->p_sys->p_visual,
p_vout->i_screen_depth, ZPixmap, 0, pb_data,
*pp_ximage = XCreateImage( p_vout->p_sys->p_display,
p_vout->p_sys->p_visual, p_vout->i_screen_depth,
ZPixmap, 0, pb_data,
p_vout->i_width, p_vout->i_height, i_quantum, 0);
if(! *pp_ximage ) /* error */
{
......@@ -823,129 +956,6 @@ static void X11DestroyShmImage( vout_thread_t *p_vout, XImage *p_ximage,
/* WAZAAAAAAAAAAA */
/*****************************************************************************
* X11CreateWindow: open and set-up X11 main window
*****************************************************************************/
static int X11CreateWindow( vout_thread_t *p_vout )
{
XSizeHints xsize_hints;
XSetWindowAttributes xwindow_attributes;
XGCValues xgcvalues;
XEvent xevent;
boolean_t b_expose;
boolean_t b_configure_notify;
boolean_t b_map_notify;
/* Set main window's size */
p_vout->p_sys->i_width = main_GetIntVariable( VOUT_WIDTH_VAR,
VOUT_WIDTH_DEFAULT );
p_vout->p_sys->i_height = main_GetIntVariable( VOUT_HEIGHT_VAR,
VOUT_HEIGHT_DEFAULT );
/* Prepare window manager hints and properties */
xsize_hints.base_width = p_vout->p_sys->i_width;
xsize_hints.base_height = p_vout->p_sys->i_height;
xsize_hints.flags = PSize;
p_vout->p_sys->wm_protocols = XInternAtom( p_vout->p_sys->p_display,
"WM_PROTOCOLS", True );
p_vout->p_sys->wm_delete_window = XInternAtom( p_vout->p_sys->p_display,
"WM_DELETE_WINDOW", True );
/* Prepare window attributes */
xwindow_attributes.backing_store = Always; /* save the hidden part */
xwindow_attributes.background_pixel = WhitePixel( p_vout->p_sys->p_display,
p_vout->p_sys->i_screen );
xwindow_attributes.event_mask = ExposureMask | StructureNotifyMask;
/* Create the window and set hints - the window must receive ConfigureNotify
* events, and, until it is displayed, Expose and MapNotify events. */
p_vout->p_sys->window =
XCreateWindow( p_vout->p_sys->p_display,
DefaultRootWindow( p_vout->p_sys->p_display ),
0, 0,
p_vout->p_sys->i_width, p_vout->p_sys->i_height, 1,
0, InputOutput, 0,
CWBackingStore | CWBackPixel | CWEventMask,
&xwindow_attributes );
/* Set window manager hints and properties: size hints, command,
* window's name, and accepted protocols */
XSetWMNormalHints( p_vout->p_sys->p_display, p_vout->p_sys->window,
&xsize_hints );
XSetCommand( p_vout->p_sys->p_display, p_vout->p_sys->window,
p_main->ppsz_argv, p_main->i_argc );
XStoreName( p_vout->p_sys->p_display, p_vout->p_sys->window, VOUT_TITLE );
if( (p_vout->p_sys->wm_protocols == None) /* use WM_DELETE_WINDOW */
|| (p_vout->p_sys->wm_delete_window == None)
|| !XSetWMProtocols( p_vout->p_sys->p_display, p_vout->p_sys->window,
&p_vout->p_sys->wm_delete_window, 1 ) )
{
/* WM_DELETE_WINDOW is not supported by window manager */
intf_Msg("intf error: missing or bad window manager - please exit program kindly.");
}
/* Creation of a graphic context that doesn't generate a GraphicsExpose
* event when using functions like XCopyArea */
xgcvalues.graphics_exposures = False;
p_vout->p_sys->gc = XCreateGC( p_vout->p_sys->p_display, p_vout->p_sys->window,
GCGraphicsExposures, &xgcvalues);
/* Send orders to server, and wait until window is displayed - three
* events must be received: a MapNotify event, an Expose event allowing
* drawing in the window, and a ConfigureNotify to get the window
* dimensions. Once those events have been received, only ConfigureNotify
* events need to be received. */
b_expose = 0;
b_configure_notify = 0;
b_map_notify = 0;
XMapWindow( p_vout->p_sys->p_display, p_vout->p_sys->window);
do
{
XNextEvent( p_vout->p_sys->p_display, &xevent);
if( (xevent.type == Expose)
&& (xevent.xexpose.window == p_vout->p_sys->window) )
{
b_expose = 1;
}
else if( (xevent.type == MapNotify)
&& (xevent.xmap.window == p_vout->p_sys->window) )
{
b_map_notify = 1;
}
else if( (xevent.type == ConfigureNotify)
&& (xevent.xconfigure.window == p_vout->p_sys->window) )
{
b_configure_notify = 1;
p_vout->p_sys->i_width = xevent.xconfigure.width;
p_vout->p_sys->i_height = xevent.xconfigure.height;
}
} while( !( b_expose && b_configure_notify && b_map_notify ) );
XSelectInput( p_vout->p_sys->p_display, p_vout->p_sys->window,
StructureNotifyMask | KeyPressMask | ButtonPressMask );
if( XDefaultDepth(p_vout->p_sys->p_display, p_vout->p_sys->i_screen) == 8 )
{
/* Allocate a new palette */
p_vout->p_sys->colormap = XCreateColormap( p_vout->p_sys->p_display,
DefaultRootWindow( p_vout->p_sys->p_display ),
DefaultVisual( p_vout->p_sys->p_display,
p_vout->p_sys->i_screen ),
AllocAll );
xwindow_attributes.colormap = p_vout->p_sys->colormap;
XChangeWindowAttributes( p_vout->p_sys->p_display,
p_vout->p_sys->window,
CWColormap, &xwindow_attributes );
}
/* At this stage, the window is open, displayed, and ready to
* receive data */
return( 0 );
}
/*****************************************************************************
* X11EnableScreenSaver: enable screen saver
*****************************************************************************
......@@ -980,7 +990,8 @@ void X11DisableScreenSaver( vout_thread_t *p_vout )
/* Disable screen saver */
intf_DbgMsg("intf: disabling screen saver");
XSetScreenSaver( p_vout->p_sys->p_display, 0,
p_vout->p_sys->i_ss_interval, p_vout->p_sys->i_ss_blanking,
p_vout->p_sys->i_ss_interval,
p_vout->p_sys->i_ss_blanking,
p_vout->p_sys->i_ss_exposure );
}
......@@ -1032,3 +1043,4 @@ void X11TogglePointer( vout_thread_t *p_vout )
XUndefineCursor( p_vout->p_sys->p_display, p_vout->p_sys->window );
}
}
......@@ -4,7 +4,7 @@
* decoders.
*****************************************************************************
* Copyright (C) 1998, 1999, 2000 VideoLAN
* $Id: input.c,v 1.80 2001/02/12 13:20:14 massiot Exp $
* $Id: input.c,v 1.81 2001/02/16 06:37:09 sam Exp $
*
* Authors: Christophe Massiot <massiot@via.ecp.fr>
*
......@@ -62,8 +62,9 @@
* Local prototypes
*****************************************************************************/
static void RunThread ( input_thread_t *p_input );
static void InitThread ( input_thread_t *p_input );
static int InitThread ( input_thread_t *p_input );
static void ErrorThread ( input_thread_t *p_input );
static void DestroyThread ( input_thread_t *p_input );
static void EndThread ( input_thread_t *p_input );
/*****************************************************************************
......@@ -188,7 +189,16 @@ static void RunThread( input_thread_t *p_input )
data_packet_t * pp_packets[INPUT_READ_ONCE];
int i_error, i;
InitThread( p_input );
if( InitThread( p_input ) )
{
/* If we failed, wait before we are killed, and exit */
*p_input->pi_status = THREAD_ERROR;
p_input->b_error = 1;
ErrorThread( p_input );
DestroyThread( p_input );
return;
}
while( !p_input->b_die && !p_input->b_error && !p_input->b_eof )
{
......@@ -250,13 +260,16 @@ static void RunThread( input_thread_t *p_input )
}
EndThread( p_input );
DestroyThread( p_input );
intf_DbgMsg("Thread end");
}
/*****************************************************************************
* InitThread: init the input Thread
*****************************************************************************/
static void InitThread( input_thread_t * p_input )
static int InitThread( input_thread_t * p_input )
{
#ifdef STATS
......@@ -274,8 +287,8 @@ static void InitThread( input_thread_t * p_input )
if( p_input->p_input_module == NULL )
{
intf_ErrMsg( "input error: no suitable input module" );
p_input->b_error = 1;
return;
module_Unneed( p_main->p_bank, p_input->p_input_module );
return( -1 );
}
#define f p_input->p_input_module->p_functions->input.functions.input
......@@ -297,14 +310,17 @@ static void InitThread( input_thread_t * p_input )
if( p_input->b_error )
{
/* We barfed -- exit nicely */
p_input->pf_close( p_input );
module_Unneed( p_main->p_bank, p_input->p_input_module );
return( -1 );
}
else
{
p_input->pf_init( p_input );
}
*p_input->pi_status = THREAD_READY;
return( 0 );
}
/*****************************************************************************
......@@ -345,14 +361,25 @@ static void EndThread( input_thread_t * p_input )
/* Free all ES and destroy all decoder threads */
input_EndStream( p_input );
/* Close stream */
p_input->pf_close( p_input );
/* Free demultiplexer's data */
p_input->pf_end( p_input );
/* Close stream */
p_input->pf_close( p_input );
/* Release modules */
module_Unneed( p_main->p_bank, p_input->p_input_module );
}
/*****************************************************************************
* DestroyThread: destroy the input thread
*****************************************************************************/
static void DestroyThread( input_thread_t * p_input )
{
int * pi_status; /* thread status */
/* Store status */
pi_status = p_input->pi_status;
/* Destroy Mutex locks */
vlc_mutex_destroy( &p_input->stream.control.control_lock );
......
......@@ -39,27 +39,33 @@
#include "input.h"
/*****************************************************************************
* input_SetRate: change the reading pace
* input_SetStatus: change the reading status
*****************************************************************************/
void input_SetRate( input_thread_t * p_input, int i_mode )
void input_SetStatus( input_thread_t * p_input, int i_mode )
{
vlc_mutex_lock( &p_input->stream.stream_lock );
switch( i_mode )
{
case INPUT_RATE_PLAY:
case INPUT_STATUS_END:
p_input->stream.i_new_status = PLAYING_S;
p_input->b_eof = 1;
intf_Msg( "input: end of stream" );
break;
case INPUT_STATUS_PLAY:
p_input->stream.i_new_status = PLAYING_S;
intf_Msg( "input: playing at normal rate" );
break;
case INPUT_RATE_PAUSE:
case INPUT_STATUS_PAUSE:
/* XXX: we don't need to check i_status, because input_clock.c
* does it for us */
p_input->stream.i_new_status = PAUSE_S;
intf_Msg( "input: toggling pause" );
break;
case INPUT_RATE_FASTER:
case INPUT_STATUS_FASTER:
/* If we are already going too fast, go back to default rate */
if( p_input->stream.control.i_rate * 8 <= DEFAULT_RATE )
{
......@@ -85,7 +91,7 @@ void input_SetRate( input_thread_t * p_input, int i_mode )
}
break;
case INPUT_RATE_SLOWER:
case INPUT_STATUS_SLOWER:
/* If we are already going too slow, go back to default rate */
if( p_input->stream.control.i_rate >= 8 * DEFAULT_RATE )
{
......@@ -118,6 +124,14 @@ void input_SetRate( input_thread_t * p_input, int i_mode )
vlc_mutex_unlock( &p_input->stream.stream_lock );
}
/*****************************************************************************
* input_SetRate: change the reading rate
*****************************************************************************/
void input_SetRate( input_thread_t * p_input, int i_mode )
{
; /* FIXME: stub */
}
/*****************************************************************************
* input_Seek: changes the stream postion
*****************************************************************************/
......
......@@ -349,19 +349,17 @@ int intf_ProcessKey( intf_thread_t *p_intf, int g_key )
case INTF_KEY_DEC_GAMMA: /* gamma - */
if( (p_main->p_vout != NULL) && (p_main->p_vout->f_gamma > -INTF_GAMMA_LIMIT) )
{
vlc_mutex_lock( &p_main->p_vout->change_lock );
/* FIXME: we should lock if called from the interface */
p_main->p_vout->f_gamma -= INTF_GAMMA_STEP;
p_main->p_vout->i_changes |= VOUT_GAMMA_CHANGE;
vlc_mutex_unlock( &p_main->p_vout->change_lock );
}
break;
case INTF_KEY_INC_GAMMA: /* gamma + */
if( (p_main->p_vout != NULL) && (p_main->p_vout->f_gamma < INTF_GAMMA_LIMIT) )
{
vlc_mutex_lock( &p_main->p_vout->change_lock );
/* FIXME: we should lock if called from the interface */
p_main->p_vout->f_gamma += INTF_GAMMA_STEP;
p_main->p_vout->i_changes |= VOUT_GAMMA_CHANGE;
vlc_mutex_unlock( &p_main->p_vout->change_lock );
}
break;
default: /* unknown key */
......
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