Test for poll() and disable IPV6 if not found.

merge-requests/1/head
Henning Geinitz 2003-05-02 09:41:12 +00:00
rodzic ac69383660
commit e93322e28d
5 zmienionych plików z 47 dodań i 33 usunięć

Wyświetl plik

@ -1,3 +1,9 @@
2003-05-02 Henning Meier-Geinitz <henning@meier-geinitz.de>
* configure configure.in frontend/saned.c
include/sane/config.h.in: Test for poll() and disable IPV6 if
not found.
2003-05-01 Oliver Rauch <Oliver.Rauch@XSane.org> 2003-05-01 Oliver Rauch <Oliver.Rauch@XSane.org>
* backend/ * backend/

63
configure vendored
Wyświetl plik

@ -8171,10 +8171,11 @@ rm -f conftest.mmap
for ac_func in atexit inet_addr inet_aton inet_ntoa ioperm mkdir \ for ac_func in atexit inet_addr inet_aton inet_ntoa ioperm mkdir \
scsireq_enter strftime strstr strtod \ scsireq_enter strftime strstr strtod \
cfmakeraw tcsendbreak strcasecmp strncasecmp _portaccess \ cfmakeraw tcsendbreak strcasecmp strncasecmp _portaccess \
getaddrinfo getnameinfo getaddrinfo getnameinfo poll
do do
as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh` as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
echo "$as_me:$LINENO: checking for $ac_func" >&5 echo "$as_me:$LINENO: checking for $ac_func" >&5
@ -8469,7 +8470,9 @@ _ACEOF
fi fi
if test "$ac_cv_func_getnameinfo" = "yes" && test "$ac_cv_func_getaddrinfo" = "yes" ; then if test "$ac_cv_func_getnameinfo" = "yes" \
&& test "$ac_cv_func_getaddrinfo" = "yes" \
&& test "$ac_cv_func_poll" = "yes" ; then
echo "$as_me:$LINENO: checking whether to enable IPv6" >&5 echo "$as_me:$LINENO: checking whether to enable IPv6" >&5
echo $ECHO_N "checking whether to enable IPv6... $ECHO_C" >&6 echo $ECHO_N "checking whether to enable IPv6... $ECHO_C" >&6
@ -9107,7 +9110,7 @@ ia64-*-hpux*)
;; ;;
*-*-irix6*) *-*-irix6*)
# Find out which ABI we are using. # Find out which ABI we are using.
echo '#line 9110 "configure"' > conftest.$ac_ext echo '#line 9113 "configure"' > conftest.$ac_ext
if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5 if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
(eval $ac_compile) 2>&5 (eval $ac_compile) 2>&5
ac_status=$? ac_status=$?
@ -10286,7 +10289,7 @@ fi
# Provide some information about the compiler. # Provide some information about the compiler.
echo "$as_me:10289:" \ echo "$as_me:10292:" \
"checking for Fortran 77 compiler version" >&5 "checking for Fortran 77 compiler version" >&5
ac_compiler=`set X $ac_compile; echo $2` ac_compiler=`set X $ac_compile; echo $2`
{ (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5 { (eval echo "$as_me:$LINENO: \"$ac_compiler --version </dev/null >&5\"") >&5
@ -11291,11 +11294,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:11294: $lt_compile\"" >&5) (eval echo "\"\$as_me:11297: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:11298: \$? = $ac_status" >&5 echo "$as_me:11301: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -11523,11 +11526,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:11526: $lt_compile\"" >&5) (eval echo "\"\$as_me:11529: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:11530: \$? = $ac_status" >&5 echo "$as_me:11533: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -11590,11 +11593,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:11593: $lt_compile\"" >&5) (eval echo "\"\$as_me:11596: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err) (eval "$lt_compile" 2>out/conftest.err)
ac_status=$? ac_status=$?
cat out/conftest.err >&5 cat out/conftest.err >&5
echo "$as_me:11597: \$? = $ac_status" >&5 echo "$as_me:11600: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext if (exit $ac_status) && test -s out/conftest2.$ac_objext
then then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
@ -13602,7 +13605,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 13605 "configure" #line 13608 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H
@ -13700,7 +13703,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 13703 "configure" #line 13706 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H
@ -15832,11 +15835,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:15835: $lt_compile\"" >&5) (eval echo "\"\$as_me:15838: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:15839: \$? = $ac_status" >&5 echo "$as_me:15842: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -15899,11 +15902,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:15902: $lt_compile\"" >&5) (eval echo "\"\$as_me:15905: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err) (eval "$lt_compile" 2>out/conftest.err)
ac_status=$? ac_status=$?
cat out/conftest.err >&5 cat out/conftest.err >&5
echo "$as_me:15906: \$? = $ac_status" >&5 echo "$as_me:15909: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext if (exit $ac_status) && test -s out/conftest2.$ac_objext
then then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
@ -17142,7 +17145,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 17145 "configure" #line 17148 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H
@ -17240,7 +17243,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 17243 "configure" #line 17246 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H
@ -18062,11 +18065,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:18065: $lt_compile\"" >&5) (eval echo "\"\$as_me:18068: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:18069: \$? = $ac_status" >&5 echo "$as_me:18072: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -18129,11 +18132,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:18132: $lt_compile\"" >&5) (eval echo "\"\$as_me:18135: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err) (eval "$lt_compile" 2>out/conftest.err)
ac_status=$? ac_status=$?
cat out/conftest.err >&5 cat out/conftest.err >&5
echo "$as_me:18136: \$? = $ac_status" >&5 echo "$as_me:18139: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext if (exit $ac_status) && test -s out/conftest2.$ac_objext
then then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
@ -20069,11 +20072,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:20072: $lt_compile\"" >&5) (eval echo "\"\$as_me:20075: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:20076: \$? = $ac_status" >&5 echo "$as_me:20079: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -20301,11 +20304,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:20304: $lt_compile\"" >&5) (eval echo "\"\$as_me:20307: $lt_compile\"" >&5)
(eval "$lt_compile" 2>conftest.err) (eval "$lt_compile" 2>conftest.err)
ac_status=$? ac_status=$?
cat conftest.err >&5 cat conftest.err >&5
echo "$as_me:20308: \$? = $ac_status" >&5 echo "$as_me:20311: \$? = $ac_status" >&5
if (exit $ac_status) && test -s "$ac_outfile"; then if (exit $ac_status) && test -s "$ac_outfile"; then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
# So say no if there are warnings # So say no if there are warnings
@ -20368,11 +20371,11 @@ else
-e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \ -e 's:.*FLAGS}? :&$lt_compiler_flag :; t' \
-e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \ -e 's: [^ ]*conftest\.: $lt_compiler_flag&:; t' \
-e 's:$: $lt_compiler_flag:'` -e 's:$: $lt_compiler_flag:'`
(eval echo "\"\$as_me:20371: $lt_compile\"" >&5) (eval echo "\"\$as_me:20374: $lt_compile\"" >&5)
(eval "$lt_compile" 2>out/conftest.err) (eval "$lt_compile" 2>out/conftest.err)
ac_status=$? ac_status=$?
cat out/conftest.err >&5 cat out/conftest.err >&5
echo "$as_me:20375: \$? = $ac_status" >&5 echo "$as_me:20378: \$? = $ac_status" >&5
if (exit $ac_status) && test -s out/conftest2.$ac_objext if (exit $ac_status) && test -s out/conftest2.$ac_objext
then then
# The compiler can only warn and ignore the option if not recognized # The compiler can only warn and ignore the option if not recognized
@ -22380,7 +22383,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 22383 "configure" #line 22386 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H
@ -22478,7 +22481,7 @@ else
lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2 lt_dlunknown=0; lt_dlno_uscore=1; lt_dlneed_uscore=2
lt_status=$lt_dlunknown lt_status=$lt_dlunknown
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 22481 "configure" #line 22484 "configure"
#include "confdefs.h" #include "confdefs.h"
#if HAVE_DLFCN_H #if HAVE_DLFCN_H

Wyświetl plik

@ -186,7 +186,7 @@ AC_FUNC_MMAP
AC_CHECK_FUNCS(atexit inet_addr inet_aton inet_ntoa ioperm mkdir \ AC_CHECK_FUNCS(atexit inet_addr inet_aton inet_ntoa ioperm mkdir \
scsireq_enter strftime strstr strtod \ scsireq_enter strftime strstr strtod \
cfmakeraw tcsendbreak strcasecmp strncasecmp _portaccess \ cfmakeraw tcsendbreak strcasecmp strncasecmp _portaccess \
getaddrinfo getnameinfo) getaddrinfo getnameinfo poll)
AC_REPLACE_FUNCS(getenv inet_ntop inet_pton isfdtype sigprocmask snprintf \ AC_REPLACE_FUNCS(getenv inet_ntop inet_pton isfdtype sigprocmask snprintf \
strdup strndup strsep usleep vsyslog) strdup strndup strsep usleep vsyslog)
SANE_PROTOTYPES SANE_PROTOTYPES
@ -227,7 +227,9 @@ if sparc64 -q > /dev/null 2>&1 ; then
fi fi
dnl check for IPv6 (can be overriden by --enable-ipv6) dnl check for IPv6 (can be overriden by --enable-ipv6)
if test "$ac_cv_func_getnameinfo" = "yes" && test "$ac_cv_func_getaddrinfo" = "yes" ; then if test "$ac_cv_func_getnameinfo" = "yes" \
&& test "$ac_cv_func_getaddrinfo" = "yes" \
&& test "$ac_cv_func_poll" = "yes" ; then
SANE_CHECK_IPV6 SANE_CHECK_IPV6
else else
ipv6="no" ipv6="no"

Wyświetl plik

@ -32,7 +32,7 @@
#include "../include/lalloca.h" #include "../include/lalloca.h"
#include "../include/sys/types.h" #include "../include/sys/types.h"
#if defined(HAVE_GETADDRINFO) && defined (HAVE_GETNAMEINFO) #if defined(HAVE_GETADDRINFO) && defined (HAVE_GETNAMEINFO) && defined (HAVE_POLL)
# define SANED_USES_AF_INDEP # define SANED_USES_AF_INDEP
#else #else
# undef ENABLE_IPV6 # undef ENABLE_IPV6

Wyświetl plik

@ -150,6 +150,9 @@
/* Define to 1 if you have the <os2.h> header file. */ /* Define to 1 if you have the <os2.h> header file. */
#undef HAVE_OS2_H #undef HAVE_OS2_H
/* Define to 1 if you have the `poll' function. */
#undef HAVE_POLL
/* Define to 1 if you have the `scsireq_enter' function. */ /* Define to 1 if you have the `scsireq_enter' function. */
#undef HAVE_SCSIREQ_ENTER #undef HAVE_SCSIREQ_ENTER