ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/rxvt-unicode/configure
(Generate patch)

Comparing rxvt-unicode/configure (file contents):
Revision 1.87 by root, Sat Jan 21 23:50:33 2006 UTC vs.
Revision 1.88 by root, Sun Jan 22 00:48:13 2006 UTC

10181 10181
10182fi 10182fi
10183done 10183done
10184 10184
10185 10185
10186UTMP_CHECK 10186
10187
10188
10189
10190for ac_func in \
10191 ttyslot \
10192 updwtmp \
10193 updwtmpx \
10194
10195do
10196as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
10197echo "$as_me:$LINENO: checking for $ac_func" >&5
10198echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
10199if eval "test \"\${$as_ac_var+set}\" = set"; then
10200 echo $ECHO_N "(cached) $ECHO_C" >&6
10201else
10202 cat >conftest.$ac_ext <<_ACEOF
10203/* confdefs.h. */
10204_ACEOF
10205cat confdefs.h >>conftest.$ac_ext
10206cat >>conftest.$ac_ext <<_ACEOF
10207/* end confdefs.h. */
10208/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
10209 For example, HP-UX 11i <limits.h> declares gettimeofday. */
10210#define $ac_func innocuous_$ac_func
10211
10212/* System header to define __stub macros and hopefully few prototypes,
10213 which can conflict with char $ac_func (); below.
10214 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
10215 <limits.h> exists even on freestanding compilers. */
10216
10217#ifdef __STDC__
10218# include <limits.h>
10219#else
10220# include <assert.h>
10221#endif
10222
10223#undef $ac_func
10224
10225/* Override any gcc2 internal prototype to avoid an error. */
10226#ifdef __cplusplus
10227extern "C"
10228{
10229#endif
10230/* We use char because int might match the return type of a gcc2
10231 builtin and then its argument prototype would still apply. */
10232char $ac_func ();
10233/* The GNU C library defines this for functions which it implements
10234 to always fail with ENOSYS. Some functions are actually named
10235 something starting with __ and the normal name is an alias. */
10236#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
10237choke me
10238#else
10239char (*f) () = $ac_func;
10240#endif
10241#ifdef __cplusplus
10242}
10243#endif
10244
10245int
10246main ()
10247{
10248return f != $ac_func;
10249 ;
10250 return 0;
10251}
10252_ACEOF
10253rm -f conftest.$ac_objext conftest$ac_exeext
10254if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
10255 (eval $ac_link) 2>conftest.er1
10256 ac_status=$?
10257 grep -v '^ *+' conftest.er1 >conftest.err
10258 rm -f conftest.er1
10259 cat conftest.err >&5
10260 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10261 (exit $ac_status); } &&
10262 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10263 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10264 (eval $ac_try) 2>&5
10265 ac_status=$?
10266 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10267 (exit $ac_status); }; } &&
10268 { ac_try='test -s conftest$ac_exeext'
10269 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10270 (eval $ac_try) 2>&5
10271 ac_status=$?
10272 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10273 (exit $ac_status); }; }; then
10274 eval "$as_ac_var=yes"
10275else
10276 echo "$as_me: failed program was:" >&5
10277sed 's/^/| /' conftest.$ac_ext >&5
10278
10279eval "$as_ac_var=no"
10280fi
10281rm -f conftest.err conftest.$ac_objext \
10282 conftest$ac_exeext conftest.$ac_ext
10283fi
10284echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
10285echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
10286if test `eval echo '${'$as_ac_var'}'` = yes; then
10287 cat >>confdefs.h <<_ACEOF
10288#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
10289_ACEOF
10290
10291fi
10292done
10293
10294
10295
10296
10297
10298for ac_header in \
10299 utmp.h \
10300 utmpx.h \
10301 lastlog.h \
10302
10303do
10304as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
10305if eval "test \"\${$as_ac_Header+set}\" = set"; then
10306 echo "$as_me:$LINENO: checking for $ac_header" >&5
10307echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10308if eval "test \"\${$as_ac_Header+set}\" = set"; then
10309 echo $ECHO_N "(cached) $ECHO_C" >&6
10310fi
10311echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10312echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10313else
10314 # Is the header compilable?
10315echo "$as_me:$LINENO: checking $ac_header usability" >&5
10316echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
10317cat >conftest.$ac_ext <<_ACEOF
10318/* confdefs.h. */
10319_ACEOF
10320cat confdefs.h >>conftest.$ac_ext
10321cat >>conftest.$ac_ext <<_ACEOF
10322/* end confdefs.h. */
10323$ac_includes_default
10324#include <$ac_header>
10325_ACEOF
10326rm -f conftest.$ac_objext
10327if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10328 (eval $ac_compile) 2>conftest.er1
10329 ac_status=$?
10330 grep -v '^ *+' conftest.er1 >conftest.err
10331 rm -f conftest.er1
10332 cat conftest.err >&5
10333 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10334 (exit $ac_status); } &&
10335 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10336 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10337 (eval $ac_try) 2>&5
10338 ac_status=$?
10339 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10340 (exit $ac_status); }; } &&
10341 { ac_try='test -s conftest.$ac_objext'
10342 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10343 (eval $ac_try) 2>&5
10344 ac_status=$?
10345 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10346 (exit $ac_status); }; }; then
10347 ac_header_compiler=yes
10348else
10349 echo "$as_me: failed program was:" >&5
10350sed 's/^/| /' conftest.$ac_ext >&5
10351
10352ac_header_compiler=no
10353fi
10354rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10355echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10356echo "${ECHO_T}$ac_header_compiler" >&6
10357
10358# Is the header present?
10359echo "$as_me:$LINENO: checking $ac_header presence" >&5
10360echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
10361cat >conftest.$ac_ext <<_ACEOF
10362/* confdefs.h. */
10363_ACEOF
10364cat confdefs.h >>conftest.$ac_ext
10365cat >>conftest.$ac_ext <<_ACEOF
10366/* end confdefs.h. */
10367#include <$ac_header>
10368_ACEOF
10369if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10370 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10371 ac_status=$?
10372 grep -v '^ *+' conftest.er1 >conftest.err
10373 rm -f conftest.er1
10374 cat conftest.err >&5
10375 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10376 (exit $ac_status); } >/dev/null; then
10377 if test -s conftest.err; then
10378 ac_cpp_err=$ac_cxx_preproc_warn_flag
10379 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
10380 else
10381 ac_cpp_err=
10382 fi
10383else
10384 ac_cpp_err=yes
10385fi
10386if test -z "$ac_cpp_err"; then
10387 ac_header_preproc=yes
10388else
10389 echo "$as_me: failed program was:" >&5
10390sed 's/^/| /' conftest.$ac_ext >&5
10391
10392 ac_header_preproc=no
10393fi
10394rm -f conftest.err conftest.$ac_ext
10395echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10396echo "${ECHO_T}$ac_header_preproc" >&6
10397
10398# So? What about this header?
10399case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in
10400 yes:no: )
10401 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
10402echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
10403 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
10404echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
10405 ac_header_preproc=yes
10406 ;;
10407 no:yes:* )
10408 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
10409echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
10410 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
10411echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
10412 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
10413echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
10414 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
10415echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
10416 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
10417echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
10418 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
10419echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
10420 (
10421 cat <<\_ASBOX
10422## ------------------------------------------ ##
10423## Report this to the AC_PACKAGE_NAME lists. ##
10424## ------------------------------------------ ##
10425_ASBOX
10426 ) |
10427 sed "s/^/$as_me: WARNING: /" >&2
10428 ;;
10429esac
10430echo "$as_me:$LINENO: checking for $ac_header" >&5
10431echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
10432if eval "test \"\${$as_ac_Header+set}\" = set"; then
10433 echo $ECHO_N "(cached) $ECHO_C" >&6
10434else
10435 eval "$as_ac_Header=\$ac_header_preproc"
10436fi
10437echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
10438echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
10439
10440fi
10441if test `eval echo '${'$as_ac_Header'}'` = yes; then
10442 cat >>confdefs.h <<_ACEOF
10443#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
10444_ACEOF
10445
10446fi
10447
10448done
10449
10450
10451
10452if test "${ac_cv_header_utmp_h+set}" = set; then
10453 echo "$as_me:$LINENO: checking for utmp.h" >&5
10454echo $ECHO_N "checking for utmp.h... $ECHO_C" >&6
10455if test "${ac_cv_header_utmp_h+set}" = set; then
10456 echo $ECHO_N "(cached) $ECHO_C" >&6
10457fi
10458echo "$as_me:$LINENO: result: $ac_cv_header_utmp_h" >&5
10459echo "${ECHO_T}$ac_cv_header_utmp_h" >&6
10460else
10461 # Is the header compilable?
10462echo "$as_me:$LINENO: checking utmp.h usability" >&5
10463echo $ECHO_N "checking utmp.h usability... $ECHO_C" >&6
10464cat >conftest.$ac_ext <<_ACEOF
10465/* confdefs.h. */
10466_ACEOF
10467cat confdefs.h >>conftest.$ac_ext
10468cat >>conftest.$ac_ext <<_ACEOF
10469/* end confdefs.h. */
10470$ac_includes_default
10471#include <utmp.h>
10472_ACEOF
10473rm -f conftest.$ac_objext
10474if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10475 (eval $ac_compile) 2>conftest.er1
10476 ac_status=$?
10477 grep -v '^ *+' conftest.er1 >conftest.err
10478 rm -f conftest.er1
10479 cat conftest.err >&5
10480 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10481 (exit $ac_status); } &&
10482 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10483 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10484 (eval $ac_try) 2>&5
10485 ac_status=$?
10486 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10487 (exit $ac_status); }; } &&
10488 { ac_try='test -s conftest.$ac_objext'
10489 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10490 (eval $ac_try) 2>&5
10491 ac_status=$?
10492 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10493 (exit $ac_status); }; }; then
10494 ac_header_compiler=yes
10495else
10496 echo "$as_me: failed program was:" >&5
10497sed 's/^/| /' conftest.$ac_ext >&5
10498
10499ac_header_compiler=no
10500fi
10501rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10502echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10503echo "${ECHO_T}$ac_header_compiler" >&6
10504
10505# Is the header present?
10506echo "$as_me:$LINENO: checking utmp.h presence" >&5
10507echo $ECHO_N "checking utmp.h presence... $ECHO_C" >&6
10508cat >conftest.$ac_ext <<_ACEOF
10509/* confdefs.h. */
10510_ACEOF
10511cat confdefs.h >>conftest.$ac_ext
10512cat >>conftest.$ac_ext <<_ACEOF
10513/* end confdefs.h. */
10514#include <utmp.h>
10515_ACEOF
10516if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10517 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10518 ac_status=$?
10519 grep -v '^ *+' conftest.er1 >conftest.err
10520 rm -f conftest.er1
10521 cat conftest.err >&5
10522 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10523 (exit $ac_status); } >/dev/null; then
10524 if test -s conftest.err; then
10525 ac_cpp_err=$ac_cxx_preproc_warn_flag
10526 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
10527 else
10528 ac_cpp_err=
10529 fi
10530else
10531 ac_cpp_err=yes
10532fi
10533if test -z "$ac_cpp_err"; then
10534 ac_header_preproc=yes
10535else
10536 echo "$as_me: failed program was:" >&5
10537sed 's/^/| /' conftest.$ac_ext >&5
10538
10539 ac_header_preproc=no
10540fi
10541rm -f conftest.err conftest.$ac_ext
10542echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10543echo "${ECHO_T}$ac_header_preproc" >&6
10544
10545# So? What about this header?
10546case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in
10547 yes:no: )
10548 { echo "$as_me:$LINENO: WARNING: utmp.h: accepted by the compiler, rejected by the preprocessor!" >&5
10549echo "$as_me: WARNING: utmp.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10550 { echo "$as_me:$LINENO: WARNING: utmp.h: proceeding with the compiler's result" >&5
10551echo "$as_me: WARNING: utmp.h: proceeding with the compiler's result" >&2;}
10552 ac_header_preproc=yes
10553 ;;
10554 no:yes:* )
10555 { echo "$as_me:$LINENO: WARNING: utmp.h: present but cannot be compiled" >&5
10556echo "$as_me: WARNING: utmp.h: present but cannot be compiled" >&2;}
10557 { echo "$as_me:$LINENO: WARNING: utmp.h: check for missing prerequisite headers?" >&5
10558echo "$as_me: WARNING: utmp.h: check for missing prerequisite headers?" >&2;}
10559 { echo "$as_me:$LINENO: WARNING: utmp.h: see the Autoconf documentation" >&5
10560echo "$as_me: WARNING: utmp.h: see the Autoconf documentation" >&2;}
10561 { echo "$as_me:$LINENO: WARNING: utmp.h: section \"Present But Cannot Be Compiled\"" >&5
10562echo "$as_me: WARNING: utmp.h: section \"Present But Cannot Be Compiled\"" >&2;}
10563 { echo "$as_me:$LINENO: WARNING: utmp.h: proceeding with the preprocessor's result" >&5
10564echo "$as_me: WARNING: utmp.h: proceeding with the preprocessor's result" >&2;}
10565 { echo "$as_me:$LINENO: WARNING: utmp.h: in the future, the compiler will take precedence" >&5
10566echo "$as_me: WARNING: utmp.h: in the future, the compiler will take precedence" >&2;}
10567 (
10568 cat <<\_ASBOX
10569## ------------------------------------------ ##
10570## Report this to the AC_PACKAGE_NAME lists. ##
10571## ------------------------------------------ ##
10572_ASBOX
10573 ) |
10574 sed "s/^/$as_me: WARNING: /" >&2
10575 ;;
10576esac
10577echo "$as_me:$LINENO: checking for utmp.h" >&5
10578echo $ECHO_N "checking for utmp.h... $ECHO_C" >&6
10579if test "${ac_cv_header_utmp_h+set}" = set; then
10580 echo $ECHO_N "(cached) $ECHO_C" >&6
10581else
10582 ac_cv_header_utmp_h=$ac_header_preproc
10583fi
10584echo "$as_me:$LINENO: result: $ac_cv_header_utmp_h" >&5
10585echo "${ECHO_T}$ac_cv_header_utmp_h" >&6
10586
10587fi
10588if test $ac_cv_header_utmp_h = yes; then
10589 echo "$as_me:$LINENO: checking for struct utmp" >&5
10590echo $ECHO_N "checking for struct utmp... $ECHO_C" >&6
10591if test "${struct_utmp+set}" = set; then
10592 echo $ECHO_N "(cached) $ECHO_C" >&6
10593else
10594 cat >conftest.$ac_ext <<_ACEOF
10595/* confdefs.h. */
10596_ACEOF
10597cat confdefs.h >>conftest.$ac_ext
10598cat >>conftest.$ac_ext <<_ACEOF
10599/* end confdefs.h. */
10600#include <sys/types.h>
10601#include <utmp.h>
10602int
10603main ()
10604{
10605struct utmp ut;
10606 ;
10607 return 0;
10608}
10609_ACEOF
10610rm -f conftest.$ac_objext
10611if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10612 (eval $ac_compile) 2>conftest.er1
10613 ac_status=$?
10614 grep -v '^ *+' conftest.er1 >conftest.err
10615 rm -f conftest.er1
10616 cat conftest.err >&5
10617 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10618 (exit $ac_status); } &&
10619 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10620 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10621 (eval $ac_try) 2>&5
10622 ac_status=$?
10623 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10624 (exit $ac_status); }; } &&
10625 { ac_try='test -s conftest.$ac_objext'
10626 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10627 (eval $ac_try) 2>&5
10628 ac_status=$?
10629 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10630 (exit $ac_status); }; }; then
10631 struct_utmp=yes
10632else
10633 echo "$as_me: failed program was:" >&5
10634sed 's/^/| /' conftest.$ac_ext >&5
10635
10636struct_utmp=no
10637fi
10638rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10639fi
10640echo "$as_me:$LINENO: result: $struct_utmp" >&5
10641echo "${ECHO_T}$struct_utmp" >&6
10642if test x$struct_utmp = xyes; then
10643
10644cat >>confdefs.h <<\_ACEOF
10645#define HAVE_STRUCT_UTMP 1
10646_ACEOF
10647
10648fi
10649
10650
10651echo "$as_me:$LINENO: checking for ut_host in utmp struct" >&5
10652echo $ECHO_N "checking for ut_host in utmp struct... $ECHO_C" >&6
10653if test "${struct_utmp_host+set}" = set; then
10654 echo $ECHO_N "(cached) $ECHO_C" >&6
10655else
10656 cat >conftest.$ac_ext <<_ACEOF
10657/* confdefs.h. */
10658_ACEOF
10659cat confdefs.h >>conftest.$ac_ext
10660cat >>conftest.$ac_ext <<_ACEOF
10661/* end confdefs.h. */
10662#include <sys/types.h>
10663#include <utmp.h>
10664int
10665main ()
10666{
10667struct utmp ut; ut.ut_host;
10668 ;
10669 return 0;
10670}
10671_ACEOF
10672rm -f conftest.$ac_objext
10673if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10674 (eval $ac_compile) 2>conftest.er1
10675 ac_status=$?
10676 grep -v '^ *+' conftest.er1 >conftest.err
10677 rm -f conftest.er1
10678 cat conftest.err >&5
10679 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10680 (exit $ac_status); } &&
10681 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10682 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10683 (eval $ac_try) 2>&5
10684 ac_status=$?
10685 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10686 (exit $ac_status); }; } &&
10687 { ac_try='test -s conftest.$ac_objext'
10688 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10689 (eval $ac_try) 2>&5
10690 ac_status=$?
10691 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10692 (exit $ac_status); }; }; then
10693 struct_utmp_host=yes
10694else
10695 echo "$as_me: failed program was:" >&5
10696sed 's/^/| /' conftest.$ac_ext >&5
10697
10698struct_utmp_host=no
10699fi
10700rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10701fi
10702echo "$as_me:$LINENO: result: $struct_utmp_host" >&5
10703echo "${ECHO_T}$struct_utmp_host" >&6
10704if test x$struct_utmp_host = xyes; then
10705
10706cat >>confdefs.h <<\_ACEOF
10707#define HAVE_UTMP_HOST 1
10708_ACEOF
10709
10710fi
10711
10712echo "$as_me:$LINENO: checking for ut_pid in utmp struct" >&5
10713echo $ECHO_N "checking for ut_pid in utmp struct... $ECHO_C" >&6
10714if test "${struct_utmp_pid+set}" = set; then
10715 echo $ECHO_N "(cached) $ECHO_C" >&6
10716else
10717 cat >conftest.$ac_ext <<_ACEOF
10718/* confdefs.h. */
10719_ACEOF
10720cat confdefs.h >>conftest.$ac_ext
10721cat >>conftest.$ac_ext <<_ACEOF
10722/* end confdefs.h. */
10723#include <sys/types.h>
10724#include <utmp.h>
10725int
10726main ()
10727{
10728struct utmp ut; ut.ut_pid;
10729 ;
10730 return 0;
10731}
10732_ACEOF
10733rm -f conftest.$ac_objext
10734if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10735 (eval $ac_compile) 2>conftest.er1
10736 ac_status=$?
10737 grep -v '^ *+' conftest.er1 >conftest.err
10738 rm -f conftest.er1
10739 cat conftest.err >&5
10740 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10741 (exit $ac_status); } &&
10742 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10743 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10744 (eval $ac_try) 2>&5
10745 ac_status=$?
10746 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10747 (exit $ac_status); }; } &&
10748 { ac_try='test -s conftest.$ac_objext'
10749 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10750 (eval $ac_try) 2>&5
10751 ac_status=$?
10752 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10753 (exit $ac_status); }; }; then
10754 struct_utmp_pid=yes
10755else
10756 echo "$as_me: failed program was:" >&5
10757sed 's/^/| /' conftest.$ac_ext >&5
10758
10759struct_utmp_pid=no
10760fi
10761rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10762fi
10763echo "$as_me:$LINENO: result: $struct_utmp_pid" >&5
10764echo "${ECHO_T}$struct_utmp_pid" >&6
10765if test x$struct_utmp_pid = xyes; then
10766
10767cat >>confdefs.h <<\_ACEOF
10768#define HAVE_UTMP_PID 1
10769_ACEOF
10770
10771fi
10772
10773fi
10774
10775
10776
10777if test "${ac_cv_header_utmpx_h+set}" = set; then
10778 echo "$as_me:$LINENO: checking for utmpx.h" >&5
10779echo $ECHO_N "checking for utmpx.h... $ECHO_C" >&6
10780if test "${ac_cv_header_utmpx_h+set}" = set; then
10781 echo $ECHO_N "(cached) $ECHO_C" >&6
10782fi
10783echo "$as_me:$LINENO: result: $ac_cv_header_utmpx_h" >&5
10784echo "${ECHO_T}$ac_cv_header_utmpx_h" >&6
10785else
10786 # Is the header compilable?
10787echo "$as_me:$LINENO: checking utmpx.h usability" >&5
10788echo $ECHO_N "checking utmpx.h usability... $ECHO_C" >&6
10789cat >conftest.$ac_ext <<_ACEOF
10790/* confdefs.h. */
10791_ACEOF
10792cat confdefs.h >>conftest.$ac_ext
10793cat >>conftest.$ac_ext <<_ACEOF
10794/* end confdefs.h. */
10795$ac_includes_default
10796#include <utmpx.h>
10797_ACEOF
10798rm -f conftest.$ac_objext
10799if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10800 (eval $ac_compile) 2>conftest.er1
10801 ac_status=$?
10802 grep -v '^ *+' conftest.er1 >conftest.err
10803 rm -f conftest.er1
10804 cat conftest.err >&5
10805 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10806 (exit $ac_status); } &&
10807 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10808 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10809 (eval $ac_try) 2>&5
10810 ac_status=$?
10811 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10812 (exit $ac_status); }; } &&
10813 { ac_try='test -s conftest.$ac_objext'
10814 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10815 (eval $ac_try) 2>&5
10816 ac_status=$?
10817 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10818 (exit $ac_status); }; }; then
10819 ac_header_compiler=yes
10820else
10821 echo "$as_me: failed program was:" >&5
10822sed 's/^/| /' conftest.$ac_ext >&5
10823
10824ac_header_compiler=no
10825fi
10826rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10827echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
10828echo "${ECHO_T}$ac_header_compiler" >&6
10829
10830# Is the header present?
10831echo "$as_me:$LINENO: checking utmpx.h presence" >&5
10832echo $ECHO_N "checking utmpx.h presence... $ECHO_C" >&6
10833cat >conftest.$ac_ext <<_ACEOF
10834/* confdefs.h. */
10835_ACEOF
10836cat confdefs.h >>conftest.$ac_ext
10837cat >>conftest.$ac_ext <<_ACEOF
10838/* end confdefs.h. */
10839#include <utmpx.h>
10840_ACEOF
10841if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
10842 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
10843 ac_status=$?
10844 grep -v '^ *+' conftest.er1 >conftest.err
10845 rm -f conftest.er1
10846 cat conftest.err >&5
10847 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10848 (exit $ac_status); } >/dev/null; then
10849 if test -s conftest.err; then
10850 ac_cpp_err=$ac_cxx_preproc_warn_flag
10851 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
10852 else
10853 ac_cpp_err=
10854 fi
10855else
10856 ac_cpp_err=yes
10857fi
10858if test -z "$ac_cpp_err"; then
10859 ac_header_preproc=yes
10860else
10861 echo "$as_me: failed program was:" >&5
10862sed 's/^/| /' conftest.$ac_ext >&5
10863
10864 ac_header_preproc=no
10865fi
10866rm -f conftest.err conftest.$ac_ext
10867echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
10868echo "${ECHO_T}$ac_header_preproc" >&6
10869
10870# So? What about this header?
10871case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in
10872 yes:no: )
10873 { echo "$as_me:$LINENO: WARNING: utmpx.h: accepted by the compiler, rejected by the preprocessor!" >&5
10874echo "$as_me: WARNING: utmpx.h: accepted by the compiler, rejected by the preprocessor!" >&2;}
10875 { echo "$as_me:$LINENO: WARNING: utmpx.h: proceeding with the compiler's result" >&5
10876echo "$as_me: WARNING: utmpx.h: proceeding with the compiler's result" >&2;}
10877 ac_header_preproc=yes
10878 ;;
10879 no:yes:* )
10880 { echo "$as_me:$LINENO: WARNING: utmpx.h: present but cannot be compiled" >&5
10881echo "$as_me: WARNING: utmpx.h: present but cannot be compiled" >&2;}
10882 { echo "$as_me:$LINENO: WARNING: utmpx.h: check for missing prerequisite headers?" >&5
10883echo "$as_me: WARNING: utmpx.h: check for missing prerequisite headers?" >&2;}
10884 { echo "$as_me:$LINENO: WARNING: utmpx.h: see the Autoconf documentation" >&5
10885echo "$as_me: WARNING: utmpx.h: see the Autoconf documentation" >&2;}
10886 { echo "$as_me:$LINENO: WARNING: utmpx.h: section \"Present But Cannot Be Compiled\"" >&5
10887echo "$as_me: WARNING: utmpx.h: section \"Present But Cannot Be Compiled\"" >&2;}
10888 { echo "$as_me:$LINENO: WARNING: utmpx.h: proceeding with the preprocessor's result" >&5
10889echo "$as_me: WARNING: utmpx.h: proceeding with the preprocessor's result" >&2;}
10890 { echo "$as_me:$LINENO: WARNING: utmpx.h: in the future, the compiler will take precedence" >&5
10891echo "$as_me: WARNING: utmpx.h: in the future, the compiler will take precedence" >&2;}
10892 (
10893 cat <<\_ASBOX
10894## ------------------------------------------ ##
10895## Report this to the AC_PACKAGE_NAME lists. ##
10896## ------------------------------------------ ##
10897_ASBOX
10898 ) |
10899 sed "s/^/$as_me: WARNING: /" >&2
10900 ;;
10901esac
10902echo "$as_me:$LINENO: checking for utmpx.h" >&5
10903echo $ECHO_N "checking for utmpx.h... $ECHO_C" >&6
10904if test "${ac_cv_header_utmpx_h+set}" = set; then
10905 echo $ECHO_N "(cached) $ECHO_C" >&6
10906else
10907 ac_cv_header_utmpx_h=$ac_header_preproc
10908fi
10909echo "$as_me:$LINENO: result: $ac_cv_header_utmpx_h" >&5
10910echo "${ECHO_T}$ac_cv_header_utmpx_h" >&6
10911
10912fi
10913if test $ac_cv_header_utmpx_h = yes; then
10914 echo "$as_me:$LINENO: checking for struct utmpx" >&5
10915echo $ECHO_N "checking for struct utmpx... $ECHO_C" >&6
10916if test "${struct_utmpx+set}" = set; then
10917 echo $ECHO_N "(cached) $ECHO_C" >&6
10918else
10919 cat >conftest.$ac_ext <<_ACEOF
10920/* confdefs.h. */
10921_ACEOF
10922cat confdefs.h >>conftest.$ac_ext
10923cat >>conftest.$ac_ext <<_ACEOF
10924/* end confdefs.h. */
10925#include <sys/types.h>
10926#include <utmpx.h>
10927int
10928main ()
10929{
10930struct utmpx ut;
10931 ;
10932 return 0;
10933}
10934_ACEOF
10935rm -f conftest.$ac_objext
10936if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10937 (eval $ac_compile) 2>conftest.er1
10938 ac_status=$?
10939 grep -v '^ *+' conftest.er1 >conftest.err
10940 rm -f conftest.er1
10941 cat conftest.err >&5
10942 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10943 (exit $ac_status); } &&
10944 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
10945 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10946 (eval $ac_try) 2>&5
10947 ac_status=$?
10948 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10949 (exit $ac_status); }; } &&
10950 { ac_try='test -s conftest.$ac_objext'
10951 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
10952 (eval $ac_try) 2>&5
10953 ac_status=$?
10954 echo "$as_me:$LINENO: \$? = $ac_status" >&5
10955 (exit $ac_status); }; }; then
10956 struct_utmpx=yes
10957else
10958 echo "$as_me: failed program was:" >&5
10959sed 's/^/| /' conftest.$ac_ext >&5
10960
10961struct_utmpx=no
10962fi
10963rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
10964fi
10965echo "$as_me:$LINENO: result: $struct_utmpx" >&5
10966echo "${ECHO_T}$struct_utmpx" >&6
10967if test x$struct_utmpx = xyes; then
10968
10969cat >>confdefs.h <<\_ACEOF
10970#define HAVE_STRUCT_UTMPX 1
10971_ACEOF
10972
10973fi
10974
10975
10976echo "$as_me:$LINENO: checking for host in utmpx struct" >&5
10977echo $ECHO_N "checking for host in utmpx struct... $ECHO_C" >&6
10978if test "${struct_utmpx_host+set}" = set; then
10979 echo $ECHO_N "(cached) $ECHO_C" >&6
10980else
10981 cat >conftest.$ac_ext <<_ACEOF
10982/* confdefs.h. */
10983_ACEOF
10984cat confdefs.h >>conftest.$ac_ext
10985cat >>conftest.$ac_ext <<_ACEOF
10986/* end confdefs.h. */
10987#include <sys/types.h>
10988#include <utmpx.h>
10989int
10990main ()
10991{
10992struct utmpx utx; utx.ut_host;
10993 ;
10994 return 0;
10995}
10996_ACEOF
10997rm -f conftest.$ac_objext
10998if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
10999 (eval $ac_compile) 2>conftest.er1
11000 ac_status=$?
11001 grep -v '^ *+' conftest.er1 >conftest.err
11002 rm -f conftest.er1
11003 cat conftest.err >&5
11004 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11005 (exit $ac_status); } &&
11006 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
11007 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11008 (eval $ac_try) 2>&5
11009 ac_status=$?
11010 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11011 (exit $ac_status); }; } &&
11012 { ac_try='test -s conftest.$ac_objext'
11013 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11014 (eval $ac_try) 2>&5
11015 ac_status=$?
11016 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11017 (exit $ac_status); }; }; then
11018 struct_utmpx_host=yes
11019else
11020 echo "$as_me: failed program was:" >&5
11021sed 's/^/| /' conftest.$ac_ext >&5
11022
11023struct_utmpx_host=no
11024fi
11025rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11026fi
11027echo "$as_me:$LINENO: result: $struct_utmpx_host" >&5
11028echo "${ECHO_T}$struct_utmpx_host" >&6
11029if test x$struct_utmpx_host = xyes; then
11030
11031cat >>confdefs.h <<\_ACEOF
11032#define HAVE_UTMPX_HOST 1
11033_ACEOF
11034
11035fi
11036
11037echo "$as_me:$LINENO: checking for session in utmpx struct" >&5
11038echo $ECHO_N "checking for session in utmpx struct... $ECHO_C" >&6
11039if test "${struct_utmpx_session+set}" = set; then
11040 echo $ECHO_N "(cached) $ECHO_C" >&6
11041else
11042 cat >conftest.$ac_ext <<_ACEOF
11043/* confdefs.h. */
11044_ACEOF
11045cat confdefs.h >>conftest.$ac_ext
11046cat >>conftest.$ac_ext <<_ACEOF
11047/* end confdefs.h. */
11048#include <sys/types.h>
11049#include <utmpx.h>
11050int
11051main ()
11052{
11053struct utmpx utx; utx.ut_session;
11054 ;
11055 return 0;
11056}
11057_ACEOF
11058rm -f conftest.$ac_objext
11059if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11060 (eval $ac_compile) 2>conftest.er1
11061 ac_status=$?
11062 grep -v '^ *+' conftest.er1 >conftest.err
11063 rm -f conftest.er1
11064 cat conftest.err >&5
11065 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11066 (exit $ac_status); } &&
11067 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
11068 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11069 (eval $ac_try) 2>&5
11070 ac_status=$?
11071 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11072 (exit $ac_status); }; } &&
11073 { ac_try='test -s conftest.$ac_objext'
11074 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11075 (eval $ac_try) 2>&5
11076 ac_status=$?
11077 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11078 (exit $ac_status); }; }; then
11079 struct_utmpx_session=yes
11080else
11081 echo "$as_me: failed program was:" >&5
11082sed 's/^/| /' conftest.$ac_ext >&5
11083
11084struct_utmpx_session=no
11085fi
11086rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11087fi
11088echo "$as_me:$LINENO: result: $struct_utmpx_session" >&5
11089echo "${ECHO_T}$struct_utmpx_session" >&6
11090if test x$struct_utmpx_session = xyes; then
11091
11092cat >>confdefs.h <<\_ACEOF
11093#define HAVE_UTMPX_SESSION 1
11094_ACEOF
11095
11096fi
11097
11098fi
11099
11100
11101echo "$as_me:$LINENO: checking for struct lastlog" >&5
11102echo $ECHO_N "checking for struct lastlog... $ECHO_C" >&6
11103if test "${struct_lastlog+set}" = set; then
11104 echo $ECHO_N "(cached) $ECHO_C" >&6
11105else
11106 cat >conftest.$ac_ext <<_ACEOF
11107/* confdefs.h. */
11108_ACEOF
11109cat confdefs.h >>conftest.$ac_ext
11110cat >>conftest.$ac_ext <<_ACEOF
11111/* end confdefs.h. */
11112#include <sys/types.h>
11113#include <utmp.h>
11114#ifdef HAVE_LASTLOG_H
11115#include <lastlog.h>
11116#endif
11117
11118int
11119main ()
11120{
11121struct lastlog ll;
11122 ;
11123 return 0;
11124}
11125_ACEOF
11126rm -f conftest.$ac_objext
11127if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11128 (eval $ac_compile) 2>conftest.er1
11129 ac_status=$?
11130 grep -v '^ *+' conftest.er1 >conftest.err
11131 rm -f conftest.er1
11132 cat conftest.err >&5
11133 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11134 (exit $ac_status); } &&
11135 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
11136 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11137 (eval $ac_try) 2>&5
11138 ac_status=$?
11139 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11140 (exit $ac_status); }; } &&
11141 { ac_try='test -s conftest.$ac_objext'
11142 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11143 (eval $ac_try) 2>&5
11144 ac_status=$?
11145 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11146 (exit $ac_status); }; }; then
11147 struct_lastlog=yes
11148else
11149 echo "$as_me: failed program was:" >&5
11150sed 's/^/| /' conftest.$ac_ext >&5
11151
11152struct_lastlog=no
11153fi
11154rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11155fi
11156echo "$as_me:$LINENO: result: $struct_lastlog" >&5
11157echo "${ECHO_T}$struct_lastlog" >&6
11158if test x$struct_lastlog = xyes; then
11159
11160cat >>confdefs.h <<\_ACEOF
11161#define HAVE_STRUCT_LASTLOG 1
11162_ACEOF
11163
11164fi
11165
11166echo "$as_me:$LINENO: checking for struct lastlogx" >&5
11167echo $ECHO_N "checking for struct lastlogx... $ECHO_C" >&6
11168if test "${struct_lastlogx+set}" = set; then
11169 echo $ECHO_N "(cached) $ECHO_C" >&6
11170else
11171 cat >conftest.$ac_ext <<_ACEOF
11172/* confdefs.h. */
11173_ACEOF
11174cat confdefs.h >>conftest.$ac_ext
11175cat >>conftest.$ac_ext <<_ACEOF
11176/* end confdefs.h. */
11177#include <sys/types.h>
11178#include <utmpx.h>
11179#ifdef HAVE_LASTLOG_H
11180#include <lastlog.h>
11181#endif
11182
11183int
11184main ()
11185{
11186struct lastlogx ll;
11187 ;
11188 return 0;
11189}
11190_ACEOF
11191rm -f conftest.$ac_objext
11192if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
11193 (eval $ac_compile) 2>conftest.er1
11194 ac_status=$?
11195 grep -v '^ *+' conftest.er1 >conftest.err
11196 rm -f conftest.er1
11197 cat conftest.err >&5
11198 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11199 (exit $ac_status); } &&
11200 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
11201 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11202 (eval $ac_try) 2>&5
11203 ac_status=$?
11204 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11205 (exit $ac_status); }; } &&
11206 { ac_try='test -s conftest.$ac_objext'
11207 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11208 (eval $ac_try) 2>&5
11209 ac_status=$?
11210 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11211 (exit $ac_status); }; }; then
11212 struct_lastlogx=yes
11213else
11214 echo "$as_me: failed program was:" >&5
11215sed 's/^/| /' conftest.$ac_ext >&5
11216
11217struct_lastlogx=no
11218fi
11219rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
11220fi
11221echo "$as_me:$LINENO: result: $struct_lastlogx" >&5
11222echo "${ECHO_T}$struct_lastlogx" >&6
11223if test x$struct_lastlogx = xyes; then
11224
11225cat >>confdefs.h <<\_ACEOF
11226#define HAVE_STRUCT_LASTLOGX 1
11227_ACEOF
11228
11229fi
11230
11231
11232echo "$as_me:$LINENO: checking where utmp is located" >&5
11233echo $ECHO_N "checking where utmp is located... $ECHO_C" >&6
11234if test "${path_utmp+set}" = set; then
11235 echo $ECHO_N "(cached) $ECHO_C" >&6
11236else
11237 if test "$cross_compiling" = yes; then
11238 { echo "$as_me:$LINENO: WARNING: Define UTMP_FILE in config.h manually" >&5
11239echo "$as_me: WARNING: Define UTMP_FILE in config.h manually" >&2;}
11240else
11241 cat >conftest.$ac_ext <<_ACEOF
11242/* confdefs.h. */
11243_ACEOF
11244cat confdefs.h >>conftest.$ac_ext
11245cat >>conftest.$ac_ext <<_ACEOF
11246/* end confdefs.h. */
11247#include <stdio.h>
11248#include <sys/types.h>
11249#include <utmp.h>
11250#include <errno.h>
11251main()
11252{
11253 char **u, *utmplist[] = {
11254 "/var/run/utmp", "/var/adm/utmp", "/etc/utmp", "/usr/etc/utmp", "/usr/adm/utmp", NULL };
11255 FILE *a, *f=fopen("conftestval", "w");
11256 if (!f) exit(1);
11257#ifdef UTMP_FILE
11258 fprintf(f, "%s\n", UTMP_FILE);
11259 exit(0);
11260#endif
11261#ifdef _PATH_UTMP
11262 fprintf(f, "%s\n", _PATH_UTMP);
11263 exit(0);
11264#endif
11265 for (u = utmplist; *u; u++) {
11266 if ((a = fopen(*u, "r")) != NULL || errno == EACCES) {
11267 fprintf(f, "%s\n", *u);
11268 exit(0);
11269 }
11270 }
11271 exit(0);
11272}
11273_ACEOF
11274rm -f conftest$ac_exeext
11275if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11276 (eval $ac_link) 2>&5
11277 ac_status=$?
11278 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11279 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11280 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11281 (eval $ac_try) 2>&5
11282 ac_status=$?
11283 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11284 (exit $ac_status); }; }; then
11285 path_utmp=`cat conftestval`
11286else
11287 echo "$as_me: program exited with status $ac_status" >&5
11288echo "$as_me: failed program was:" >&5
11289sed 's/^/| /' conftest.$ac_ext >&5
11290
11291( exit $ac_status )
11292path_utmp=
11293fi
11294rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11295fi
11296fi
11297echo "$as_me:$LINENO: result: $path_utmp" >&5
11298echo "${ECHO_T}$path_utmp" >&6
11299if test x$path_utmp != x; then
11300
11301cat >>confdefs.h <<_ACEOF
11302#define UTMP_FILE "$path_utmp"
11303_ACEOF
11304
11305fi
11306
11307
11308echo "$as_me:$LINENO: checking where utmpx is located" >&5
11309echo $ECHO_N "checking where utmpx is located... $ECHO_C" >&6
11310if test "${path_utmpx+set}" = set; then
11311 echo $ECHO_N "(cached) $ECHO_C" >&6
11312else
11313 if test "$cross_compiling" = yes; then
11314 { echo "$as_me:$LINENO: WARNING: Define UTMPX_FILE in config.h manually" >&5
11315echo "$as_me: WARNING: Define UTMPX_FILE in config.h manually" >&2;}
11316else
11317 cat >conftest.$ac_ext <<_ACEOF
11318/* confdefs.h. */
11319_ACEOF
11320cat confdefs.h >>conftest.$ac_ext
11321cat >>conftest.$ac_ext <<_ACEOF
11322/* end confdefs.h. */
11323#include <stdio.h>
11324#include <sys/types.h>
11325#include <utmpx.h>
11326#include <errno.h>
11327#include <sys/stat.h>
11328#ifdef HAVE_STRING_H
11329#include <string.h>
11330#endif
11331main()
11332{
11333 char **u, *p, *utmplist[] = {
11334#ifdef UTMPX_FILE
11335 UTMPX_FILE,
11336#endif
11337#ifdef _PATH_UTMPX
11338 _PATH_UTMPX,
11339#endif
11340 "/var/adm/utmpx", "/etc/utmpx", NULL };
11341 FILE *a, *f=fopen("conftestval", "w");
11342 struct stat statu, statux;
11343 if (!f) exit(1);
11344 for (u = utmplist; *u; u++) {
11345 if ((a = fopen(*u, "r")) != NULL || errno == EACCES) {
11346 if (stat(*u, &statux) < 0)
11347 continue;
11348 p = strdup(*u);
11349 p[strlen(p) - 1] = '\0';
11350 if (stat(p, &statu) >= 0
11351 && (statu.st_mtime - statux.st_mtime > 86400))
11352 continue;
11353 fprintf(f, "%s\n", *u);
11354 exit(0);
11355 }
11356 }
11357 exit(0);
11358}
11359_ACEOF
11360rm -f conftest$ac_exeext
11361if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11362 (eval $ac_link) 2>&5
11363 ac_status=$?
11364 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11365 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11366 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11367 (eval $ac_try) 2>&5
11368 ac_status=$?
11369 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11370 (exit $ac_status); }; }; then
11371 path_utmpx=`cat conftestval`
11372else
11373 echo "$as_me: program exited with status $ac_status" >&5
11374echo "$as_me: failed program was:" >&5
11375sed 's/^/| /' conftest.$ac_ext >&5
11376
11377( exit $ac_status )
11378path_utmpx=
11379fi
11380rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11381fi
11382fi
11383echo "$as_me:$LINENO: result: $path_utmpx" >&5
11384echo "${ECHO_T}$path_utmpx" >&6
11385if test x$path_utmpx != x; then
11386
11387cat >>confdefs.h <<_ACEOF
11388#define UTMPX_FILE "$path_utmpx"
11389_ACEOF
11390
11391fi
11392
11393
11394echo "$as_me:$LINENO: checking where wtmp is located" >&5
11395echo $ECHO_N "checking where wtmp is located... $ECHO_C" >&6
11396if test "${path_wtmp+set}" = set; then
11397 echo $ECHO_N "(cached) $ECHO_C" >&6
11398else
11399 if test "$cross_compiling" = yes; then
11400 { echo "$as_me:$LINENO: WARNING: Define WTMP_FILE in config.h manually" >&5
11401echo "$as_me: WARNING: Define WTMP_FILE in config.h manually" >&2;}
11402else
11403 cat >conftest.$ac_ext <<_ACEOF
11404/* confdefs.h. */
11405_ACEOF
11406cat confdefs.h >>conftest.$ac_ext
11407cat >>conftest.$ac_ext <<_ACEOF
11408/* end confdefs.h. */
11409#include <stdio.h>
11410#include <sys/types.h>
11411#ifdef HAVE_UTMP_H
11412#include <utmp.h>
11413#endif
11414#include <errno.h>
11415main()
11416{
11417 char **w, *wtmplist[] = {
11418 "/var/log/wtmp", "/var/adm/wtmp", "/etc/wtmp", "/usr/etc/wtmp", "/usr/adm/wtmp", NULL };
11419 FILE *a, *f=fopen("conftestval", "w");
11420 if (!f) exit(1);
11421#ifdef WTMP_FILE
11422 fprintf(f, "%s\n", WTMP_FILE);
11423 exit(0);
11424#endif
11425#ifdef _PATH_WTMP
11426 fprintf(f, "%s\n", _PATH_WTMP);
11427 exit(0);
11428#endif
11429 for (w = wtmplist; *w; w++) {
11430 if ((a = fopen(*w, "r")) != NULL || errno == EACCES) {
11431 fprintf(f, "%s\n", *w);
11432 exit(0);
11433 }
11434 }
11435 exit(0);
11436}
11437_ACEOF
11438rm -f conftest$ac_exeext
11439if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11440 (eval $ac_link) 2>&5
11441 ac_status=$?
11442 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11443 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11444 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11445 (eval $ac_try) 2>&5
11446 ac_status=$?
11447 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11448 (exit $ac_status); }; }; then
11449 path_wtmp=`cat conftestval`
11450else
11451 echo "$as_me: program exited with status $ac_status" >&5
11452echo "$as_me: failed program was:" >&5
11453sed 's/^/| /' conftest.$ac_ext >&5
11454
11455( exit $ac_status )
11456path_wtmp=
11457fi
11458rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11459fi
11460fi
11461echo "$as_me:$LINENO: result: $path_wtmp" >&5
11462echo "${ECHO_T}$path_wtmp" >&6
11463if test x$path_wtmp != x; then
11464
11465cat >>confdefs.h <<_ACEOF
11466#define WTMP_FILE "$path_wtmp"
11467_ACEOF
11468
11469fi
11470
11471echo "$as_me:$LINENO: checking where wtmpx is located" >&5
11472echo $ECHO_N "checking where wtmpx is located... $ECHO_C" >&6
11473if test "${path_wtmpx+set}" = set; then
11474 echo $ECHO_N "(cached) $ECHO_C" >&6
11475else
11476 if test "$cross_compiling" = yes; then
11477 { echo "$as_me:$LINENO: WARNING: Define WTMPX_FILE in config.h manually" >&5
11478echo "$as_me: WARNING: Define WTMPX_FILE in config.h manually" >&2;}
11479else
11480 cat >conftest.$ac_ext <<_ACEOF
11481/* confdefs.h. */
11482_ACEOF
11483cat confdefs.h >>conftest.$ac_ext
11484cat >>conftest.$ac_ext <<_ACEOF
11485/* end confdefs.h. */
11486#include <stdio.h>
11487#ifdef HAVE_UTMPX_H
11488#include <utmpx.h>
11489#endif
11490#include <errno.h>
11491main()
11492{
11493 char **w, *wtmplist[] = {
11494 "/var/log/wtmpx", "/var/adm/wtmpx", NULL };
11495 FILE *a, *f=fopen("conftestval", "w");
11496 if (!f) exit(1);
11497#ifdef WTMPX_FILE
11498 fprintf(f, "%s\n", WTMPX_FILE);
11499 exit(0);
11500#endif
11501#ifdef _PATH_WTMPX
11502 fprintf(f, "%s\n", _PATH_WTMPX);
11503 exit(0);
11504#endif
11505 for (w = wtmplist; *w; w++) {
11506 if ((a = fopen(*w, "r")) != NULL || errno == EACCES) {
11507 fprintf(f, "%s\n", *w);
11508 exit(0);
11509 }
11510 }
11511 exit(0);
11512}
11513_ACEOF
11514rm -f conftest$ac_exeext
11515if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11516 (eval $ac_link) 2>&5
11517 ac_status=$?
11518 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11519 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11520 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11521 (eval $ac_try) 2>&5
11522 ac_status=$?
11523 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11524 (exit $ac_status); }; }; then
11525 path_wtmpx=`cat conftestval`
11526else
11527 echo "$as_me: program exited with status $ac_status" >&5
11528echo "$as_me: failed program was:" >&5
11529sed 's/^/| /' conftest.$ac_ext >&5
11530
11531( exit $ac_status )
11532path_wtmpx=
11533fi
11534rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11535fi
11536fi
11537echo "$as_me:$LINENO: result: $path_wtmpx" >&5
11538echo "${ECHO_T}$path_wtmpx" >&6
11539if test x$path_wtmpx != x; then
11540
11541cat >>confdefs.h <<_ACEOF
11542#define WTMPX_FILE "$path_wtmpx"
11543_ACEOF
11544
11545fi
11546
11547echo "$as_me:$LINENO: checking where lastlog is located" >&5
11548echo $ECHO_N "checking where lastlog is located... $ECHO_C" >&6
11549if test "${path_lastlog+set}" = set; then
11550 echo $ECHO_N "(cached) $ECHO_C" >&6
11551else
11552 if test "$cross_compiling" = yes; then
11553 { echo "$as_me:$LINENO: WARNING: Define LASTLOG_FILE in config.h manually" >&5
11554echo "$as_me: WARNING: Define LASTLOG_FILE in config.h manually" >&2;}
11555else
11556 cat >conftest.$ac_ext <<_ACEOF
11557/* confdefs.h. */
11558_ACEOF
11559cat confdefs.h >>conftest.$ac_ext
11560cat >>conftest.$ac_ext <<_ACEOF
11561/* end confdefs.h. */
11562#include <stdio.h>
11563#include <sys/types.h>
11564#ifdef HAVE_UTMPX_H
11565#include <utmpx.h>
11566#elif defined(HAVE_UTMP_H)
11567#include <utmp.h>
11568#endif
11569#ifdef HAVE_LASTLOG_H
11570#include <lastlog.h>
11571#endif
11572#include <errno.h>
11573main()
11574{
11575 char **w, *lastloglist[] = { "/var/log/lastlog", NULL };
11576 FILE *a, *f=fopen("conftestval", "w");
11577 if (!f) exit(1);
11578#ifdef LASTLOG_FILE
11579 fprintf(f, "%s\n", LASTLOG_FILE);
11580 exit(0);
11581#endif
11582#ifdef _PATH_LASTLOG
11583 fprintf(f, "%s\n", _PATH_LASTLOG);
11584 exit(0);
11585#endif
11586 for (w = lastloglist; *w; w++) {
11587 if ((a = fopen(*w, "r")) != NULL || errno == EACCES) {
11588 fprintf(f, "%s\n", *w);
11589 exit(0);
11590 }
11591 }
11592 exit(0);
11593}
11594_ACEOF
11595rm -f conftest$ac_exeext
11596if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11597 (eval $ac_link) 2>&5
11598 ac_status=$?
11599 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11600 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11601 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11602 (eval $ac_try) 2>&5
11603 ac_status=$?
11604 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11605 (exit $ac_status); }; }; then
11606 path_lastlog=`cat conftestval`
11607else
11608 echo "$as_me: program exited with status $ac_status" >&5
11609echo "$as_me: failed program was:" >&5
11610sed 's/^/| /' conftest.$ac_ext >&5
11611
11612( exit $ac_status )
11613path_lastlog=
11614fi
11615rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11616fi
11617fi
11618echo "$as_me:$LINENO: result: $path_lastlog" >&5
11619echo "${ECHO_T}$path_lastlog" >&6
11620if test x$path_lastlog != x; then
11621
11622cat >>confdefs.h <<_ACEOF
11623#define LASTLOG_FILE "$path_lastlog"
11624_ACEOF
11625
11626 if test -d "$path_lastlog"; then
11627
11628cat >>confdefs.h <<\_ACEOF
11629#define LASTLOG_IS_DIR 1
11630_ACEOF
11631
11632 fi
11633fi
11634
11635echo "$as_me:$LINENO: checking where lastlogx is located" >&5
11636echo $ECHO_N "checking where lastlogx is located... $ECHO_C" >&6
11637if test "${path_lastlogx+set}" = set; then
11638 echo $ECHO_N "(cached) $ECHO_C" >&6
11639else
11640 if test "$cross_compiling" = yes; then
11641 { echo "$as_me:$LINENO: WARNING: Define LASTLOGX_FILE in config.h manually" >&5
11642echo "$as_me: WARNING: Define LASTLOGX_FILE in config.h manually" >&2;}
11643else
11644 cat >conftest.$ac_ext <<_ACEOF
11645/* confdefs.h. */
11646_ACEOF
11647cat confdefs.h >>conftest.$ac_ext
11648cat >>conftest.$ac_ext <<_ACEOF
11649/* end confdefs.h. */
11650#include <stdio.h>
11651#ifdef HAVE_UTMPX_H
11652#include <utmpx.h>
11653#endif
11654#include <errno.h>
11655main()
11656{
11657 char **w, *wtmplist[] = { "/var/log/lastlogx", "/var/adm/lastlogx", NULL };
11658 FILE *a, *f=fopen("conftestval", "w");
11659 if (!f) exit(1);
11660#ifdef LASTLOGX_FILE
11661 fprintf(f, "%s\n", LASTLOGX_FILE);
11662 exit(0);
11663#endif
11664#ifdef _PATH_LASTLOGX
11665 fprintf(f, "%s\n", _PATH_LASTLOGX);
11666 exit(0);
11667#endif
11668 for (w = wtmplist; *w; w++) {
11669 if ((a = fopen(*w, "r")) != NULL || errno == EACCES) {
11670 fprintf(f, "%s\n", *w);
11671 exit(0);
11672 }
11673 }
11674 exit(0);
11675}
11676_ACEOF
11677rm -f conftest$ac_exeext
11678if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
11679 (eval $ac_link) 2>&5
11680 ac_status=$?
11681 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11682 (exit $ac_status); } && { ac_try='./conftest$ac_exeext'
11683 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
11684 (eval $ac_try) 2>&5
11685 ac_status=$?
11686 echo "$as_me:$LINENO: \$? = $ac_status" >&5
11687 (exit $ac_status); }; }; then
11688 path_lastlogx=`cat conftestval`
11689else
11690 echo "$as_me: program exited with status $ac_status" >&5
11691echo "$as_me: failed program was:" >&5
11692sed 's/^/| /' conftest.$ac_ext >&5
11693
11694( exit $ac_status )
11695path_lastlogx=
11696fi
11697rm -f core *.core gmon.out bb.out conftest$ac_exeext conftest.$ac_objext conftest.$ac_ext
11698fi
11699fi
11700echo "$as_me:$LINENO: result: $path_lastlogx" >&5
11701echo "${ECHO_T}$path_lastlogx" >&6
11702if test x$path_lastlogx != x; then
11703
11704cat >>confdefs.h <<_ACEOF
11705#define LASTLOGX_FILE "$path_lastlogx"
11706_ACEOF
11707
11708fi
11709
10187 11710
10188 11711
10189echo "$as_me:$LINENO: checking where ttys/ttytab is located" >&5 11712echo "$as_me:$LINENO: checking where ttys/ttytab is located" >&5
10190echo $ECHO_N "checking where ttys/ttytab is located... $ECHO_C" >&6 11713echo $ECHO_N "checking where ttys/ttytab is located... $ECHO_C" >&6
10191if test "${rxvt_cv_path_ttytab+set}" = set; then 11714if test "${rxvt_cv_path_ttytab+set}" = set; then
10458#define HAVE_NL_LANGINFO 1 11981#define HAVE_NL_LANGINFO 1
10459_ACEOF 11982_ACEOF
10460 11983
10461fi 11984fi
10462 11985
10463SCM_RIGHTS_CHECK 11986
11987echo "$as_me:$LINENO: checking for unix-compliant filehandle passing ability" >&5
11988echo $ECHO_N "checking for unix-compliant filehandle passing ability... $ECHO_C" >&6
11989if test "${can_pass_fds+set}" = set; then
11990 echo $ECHO_N "(cached) $ECHO_C" >&6
11991else
11992 cat >conftest.$ac_ext <<_ACEOF
11993/* confdefs.h. */
11994_ACEOF
11995cat confdefs.h >>conftest.$ac_ext
11996cat >>conftest.$ac_ext <<_ACEOF
11997/* end confdefs.h. */
11998
11999#include <cstddef> // broken bsds (is that redundant) need this
12000#include <sys/types.h>
12001#include <sys/socket.h>
12002#include <sys/uio.h>
12003
12004int
12005main ()
12006{
12007
12008{
12009 msghdr msg;
12010 iovec iov;
12011 char buf [100];
12012 char data = 0;
12013
12014 iov.iov_base = &data;
12015 iov.iov_len = 1;
12016
12017 msg.msg_iov = &iov;
12018 msg.msg_iovlen = 1;
12019 msg.msg_control = buf;
12020 msg.msg_controllen = sizeof buf;
12021
12022 cmsghdr *cmsg = CMSG_FIRSTHDR (&msg);
12023 cmsg->cmsg_level = SOL_SOCKET;
12024 cmsg->cmsg_type = SCM_RIGHTS;
12025 cmsg->cmsg_len = 100;
12026
12027 *(int *)CMSG_DATA (cmsg) = 5;
12028
12029 return sendmsg (3, &msg, 0);
12030}
12031
12032 ;
12033 return 0;
12034}
12035_ACEOF
12036rm -f conftest.$ac_objext conftest$ac_exeext
12037if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12038 (eval $ac_link) 2>conftest.er1
12039 ac_status=$?
12040 grep -v '^ *+' conftest.er1 >conftest.err
12041 rm -f conftest.er1
12042 cat conftest.err >&5
12043 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12044 (exit $ac_status); } &&
12045 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12046 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12047 (eval $ac_try) 2>&5
12048 ac_status=$?
12049 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12050 (exit $ac_status); }; } &&
12051 { ac_try='test -s conftest$ac_exeext'
12052 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12053 (eval $ac_try) 2>&5
12054 ac_status=$?
12055 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12056 (exit $ac_status); }; }; then
12057 can_pass_fds=yes
12058else
12059 echo "$as_me: failed program was:" >&5
12060sed 's/^/| /' conftest.$ac_ext >&5
12061
12062can_pass_fds=no
12063fi
12064rm -f conftest.err conftest.$ac_objext \
12065 conftest$ac_exeext conftest.$ac_ext
12066fi
12067echo "$as_me:$LINENO: result: $can_pass_fds" >&5
12068echo "${ECHO_T}$can_pass_fds" >&6
12069if test x$can_pass_fds = xyes; then
12070
12071cat >>confdefs.h <<\_ACEOF
12072#define HAVE_UNIX_FDPASS 1
12073_ACEOF
12074
12075else
12076 { { echo "$as_me:$LINENO: error: libptytty requires unix-compliant filehandle passing ability" >&5
12077echo "$as_me: error: libptytty requires unix-compliant filehandle passing ability" >&2;}
12078 { (exit 1); exit 1; }; }
12079fi
12080
10464 12081
10465echo "$as_me:$LINENO: checking for broken XIM callback" >&5 12082echo "$as_me:$LINENO: checking for broken XIM callback" >&5
10466echo $ECHO_N "checking for broken XIM callback... $ECHO_C" >&6 12083echo $ECHO_N "checking for broken XIM callback... $ECHO_C" >&6
10467if test "${rxvt_broken_ximcb+set}" = set; then 12084if test "${rxvt_broken_ximcb+set}" = set; then
10468 echo $ECHO_N "(cached) $ECHO_C" >&6 12085 echo $ECHO_N "(cached) $ECHO_C" >&6
10518#define XIMCB_PROTO_BROKEN 1 12135#define XIMCB_PROTO_BROKEN 1
10519_ACEOF 12136_ACEOF
10520 12137
10521fi 12138fi
10522 12139
10523PTY_CHECK 12140
12141
12142
12143
12144
12145
12146for ac_header in \
12147 pty.h \
12148 util.h \
12149 libutil.h \
12150 sys/ioctl.h \
12151 sys/stropts.h \
12152
12153do
12154as_ac_Header=`echo "ac_cv_header_$ac_header" | $as_tr_sh`
12155if eval "test \"\${$as_ac_Header+set}\" = set"; then
12156 echo "$as_me:$LINENO: checking for $ac_header" >&5
12157echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12158if eval "test \"\${$as_ac_Header+set}\" = set"; then
12159 echo $ECHO_N "(cached) $ECHO_C" >&6
12160fi
12161echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12162echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12163else
12164 # Is the header compilable?
12165echo "$as_me:$LINENO: checking $ac_header usability" >&5
12166echo $ECHO_N "checking $ac_header usability... $ECHO_C" >&6
12167cat >conftest.$ac_ext <<_ACEOF
12168/* confdefs.h. */
12169_ACEOF
12170cat confdefs.h >>conftest.$ac_ext
12171cat >>conftest.$ac_ext <<_ACEOF
12172/* end confdefs.h. */
12173$ac_includes_default
12174#include <$ac_header>
12175_ACEOF
12176rm -f conftest.$ac_objext
12177if { (eval echo "$as_me:$LINENO: \"$ac_compile\"") >&5
12178 (eval $ac_compile) 2>conftest.er1
12179 ac_status=$?
12180 grep -v '^ *+' conftest.er1 >conftest.err
12181 rm -f conftest.er1
12182 cat conftest.err >&5
12183 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12184 (exit $ac_status); } &&
12185 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12186 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12187 (eval $ac_try) 2>&5
12188 ac_status=$?
12189 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12190 (exit $ac_status); }; } &&
12191 { ac_try='test -s conftest.$ac_objext'
12192 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12193 (eval $ac_try) 2>&5
12194 ac_status=$?
12195 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12196 (exit $ac_status); }; }; then
12197 ac_header_compiler=yes
12198else
12199 echo "$as_me: failed program was:" >&5
12200sed 's/^/| /' conftest.$ac_ext >&5
12201
12202ac_header_compiler=no
12203fi
12204rm -f conftest.err conftest.$ac_objext conftest.$ac_ext
12205echo "$as_me:$LINENO: result: $ac_header_compiler" >&5
12206echo "${ECHO_T}$ac_header_compiler" >&6
12207
12208# Is the header present?
12209echo "$as_me:$LINENO: checking $ac_header presence" >&5
12210echo $ECHO_N "checking $ac_header presence... $ECHO_C" >&6
12211cat >conftest.$ac_ext <<_ACEOF
12212/* confdefs.h. */
12213_ACEOF
12214cat confdefs.h >>conftest.$ac_ext
12215cat >>conftest.$ac_ext <<_ACEOF
12216/* end confdefs.h. */
12217#include <$ac_header>
12218_ACEOF
12219if { (eval echo "$as_me:$LINENO: \"$ac_cpp conftest.$ac_ext\"") >&5
12220 (eval $ac_cpp conftest.$ac_ext) 2>conftest.er1
12221 ac_status=$?
12222 grep -v '^ *+' conftest.er1 >conftest.err
12223 rm -f conftest.er1
12224 cat conftest.err >&5
12225 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12226 (exit $ac_status); } >/dev/null; then
12227 if test -s conftest.err; then
12228 ac_cpp_err=$ac_cxx_preproc_warn_flag
12229 ac_cpp_err=$ac_cpp_err$ac_cxx_werror_flag
12230 else
12231 ac_cpp_err=
12232 fi
12233else
12234 ac_cpp_err=yes
12235fi
12236if test -z "$ac_cpp_err"; then
12237 ac_header_preproc=yes
12238else
12239 echo "$as_me: failed program was:" >&5
12240sed 's/^/| /' conftest.$ac_ext >&5
12241
12242 ac_header_preproc=no
12243fi
12244rm -f conftest.err conftest.$ac_ext
12245echo "$as_me:$LINENO: result: $ac_header_preproc" >&5
12246echo "${ECHO_T}$ac_header_preproc" >&6
12247
12248# So? What about this header?
12249case $ac_header_compiler:$ac_header_preproc:$ac_cxx_preproc_warn_flag in
12250 yes:no: )
12251 { echo "$as_me:$LINENO: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&5
12252echo "$as_me: WARNING: $ac_header: accepted by the compiler, rejected by the preprocessor!" >&2;}
12253 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the compiler's result" >&5
12254echo "$as_me: WARNING: $ac_header: proceeding with the compiler's result" >&2;}
12255 ac_header_preproc=yes
12256 ;;
12257 no:yes:* )
12258 { echo "$as_me:$LINENO: WARNING: $ac_header: present but cannot be compiled" >&5
12259echo "$as_me: WARNING: $ac_header: present but cannot be compiled" >&2;}
12260 { echo "$as_me:$LINENO: WARNING: $ac_header: check for missing prerequisite headers?" >&5
12261echo "$as_me: WARNING: $ac_header: check for missing prerequisite headers?" >&2;}
12262 { echo "$as_me:$LINENO: WARNING: $ac_header: see the Autoconf documentation" >&5
12263echo "$as_me: WARNING: $ac_header: see the Autoconf documentation" >&2;}
12264 { echo "$as_me:$LINENO: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&5
12265echo "$as_me: WARNING: $ac_header: section \"Present But Cannot Be Compiled\"" >&2;}
12266 { echo "$as_me:$LINENO: WARNING: $ac_header: proceeding with the preprocessor's result" >&5
12267echo "$as_me: WARNING: $ac_header: proceeding with the preprocessor's result" >&2;}
12268 { echo "$as_me:$LINENO: WARNING: $ac_header: in the future, the compiler will take precedence" >&5
12269echo "$as_me: WARNING: $ac_header: in the future, the compiler will take precedence" >&2;}
12270 (
12271 cat <<\_ASBOX
12272## ------------------------------------------ ##
12273## Report this to the AC_PACKAGE_NAME lists. ##
12274## ------------------------------------------ ##
12275_ASBOX
12276 ) |
12277 sed "s/^/$as_me: WARNING: /" >&2
12278 ;;
12279esac
12280echo "$as_me:$LINENO: checking for $ac_header" >&5
12281echo $ECHO_N "checking for $ac_header... $ECHO_C" >&6
12282if eval "test \"\${$as_ac_Header+set}\" = set"; then
12283 echo $ECHO_N "(cached) $ECHO_C" >&6
12284else
12285 eval "$as_ac_Header=\$ac_header_preproc"
12286fi
12287echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_Header'}'`" >&5
12288echo "${ECHO_T}`eval echo '${'$as_ac_Header'}'`" >&6
12289
12290fi
12291if test `eval echo '${'$as_ac_Header'}'` = yes; then
12292 cat >>confdefs.h <<_ACEOF
12293#define `echo "HAVE_$ac_header" | $as_tr_cpp` 1
12294_ACEOF
12295
12296fi
12297
12298done
12299
12300
12301
12302
12303
12304
12305
12306for ac_func in \
12307 revoke \
12308 _getpty \
12309 getpt \
12310 posix_openpt \
12311 isastream \
12312
12313do
12314as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12315echo "$as_me:$LINENO: checking for $ac_func" >&5
12316echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12317if eval "test \"\${$as_ac_var+set}\" = set"; then
12318 echo $ECHO_N "(cached) $ECHO_C" >&6
12319else
12320 cat >conftest.$ac_ext <<_ACEOF
12321/* confdefs.h. */
12322_ACEOF
12323cat confdefs.h >>conftest.$ac_ext
12324cat >>conftest.$ac_ext <<_ACEOF
12325/* end confdefs.h. */
12326/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12327 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12328#define $ac_func innocuous_$ac_func
12329
12330/* System header to define __stub macros and hopefully few prototypes,
12331 which can conflict with char $ac_func (); below.
12332 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12333 <limits.h> exists even on freestanding compilers. */
12334
12335#ifdef __STDC__
12336# include <limits.h>
12337#else
12338# include <assert.h>
12339#endif
12340
12341#undef $ac_func
12342
12343/* Override any gcc2 internal prototype to avoid an error. */
12344#ifdef __cplusplus
12345extern "C"
12346{
12347#endif
12348/* We use char because int might match the return type of a gcc2
12349 builtin and then its argument prototype would still apply. */
12350char $ac_func ();
12351/* The GNU C library defines this for functions which it implements
12352 to always fail with ENOSYS. Some functions are actually named
12353 something starting with __ and the normal name is an alias. */
12354#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12355choke me
12356#else
12357char (*f) () = $ac_func;
12358#endif
12359#ifdef __cplusplus
12360}
12361#endif
12362
12363int
12364main ()
12365{
12366return f != $ac_func;
12367 ;
12368 return 0;
12369}
12370_ACEOF
12371rm -f conftest.$ac_objext conftest$ac_exeext
12372if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12373 (eval $ac_link) 2>conftest.er1
12374 ac_status=$?
12375 grep -v '^ *+' conftest.er1 >conftest.err
12376 rm -f conftest.er1
12377 cat conftest.err >&5
12378 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12379 (exit $ac_status); } &&
12380 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12381 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12382 (eval $ac_try) 2>&5
12383 ac_status=$?
12384 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12385 (exit $ac_status); }; } &&
12386 { ac_try='test -s conftest$ac_exeext'
12387 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12388 (eval $ac_try) 2>&5
12389 ac_status=$?
12390 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12391 (exit $ac_status); }; }; then
12392 eval "$as_ac_var=yes"
12393else
12394 echo "$as_me: failed program was:" >&5
12395sed 's/^/| /' conftest.$ac_ext >&5
12396
12397eval "$as_ac_var=no"
12398fi
12399rm -f conftest.err conftest.$ac_objext \
12400 conftest$ac_exeext conftest.$ac_ext
12401fi
12402echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12403echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12404if test `eval echo '${'$as_ac_var'}'` = yes; then
12405 cat >>confdefs.h <<_ACEOF
12406#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12407_ACEOF
12408
12409fi
12410done
12411
12412
12413have_clone=no
12414
12415echo "$as_me:$LINENO: checking for /dev/ptym/clone" >&5
12416echo $ECHO_N "checking for /dev/ptym/clone... $ECHO_C" >&6
12417if test -e /dev/ptym/clone; then
12418 echo "$as_me:$LINENO: result: yes" >&5
12419echo "${ECHO_T}yes" >&6
12420
12421cat >>confdefs.h <<\_ACEOF
12422#define HAVE_DEV_CLONE 1
12423_ACEOF
12424
12425
12426cat >>confdefs.h <<\_ACEOF
12427#define CLONE_DEVICE "/dev/ptym/clone"
12428_ACEOF
12429
12430 have_clone=yes
12431else
12432 echo "$as_me:$LINENO: result: no" >&5
12433echo "${ECHO_T}no" >&6
12434fi
12435
12436echo "$as_me:$LINENO: checking for /dev/ptc" >&5
12437echo $ECHO_N "checking for /dev/ptc... $ECHO_C" >&6
12438if test -e /dev/ptc; then
12439 echo "$as_me:$LINENO: result: yes" >&5
12440echo "${ECHO_T}yes" >&6
12441
12442cat >>confdefs.h <<\_ACEOF
12443#define HAVE_DEV_PTC 1
12444_ACEOF
12445
12446
12447cat >>confdefs.h <<\_ACEOF
12448#define CLONE_DEVICE "/dev/ptc"
12449_ACEOF
12450
12451 have_clone=yes
12452else
12453 echo "$as_me:$LINENO: result: no" >&5
12454echo "${ECHO_T}no" >&6
12455fi
12456
12457case $host in
12458 *-*-cygwin*)
12459 have_clone=yes
12460
12461cat >>confdefs.h <<\_ACEOF
12462#define CLONE_DEVICE "/dev/ptmx"
12463_ACEOF
12464
12465 ;;
12466 *)
12467 echo "$as_me:$LINENO: checking for /dev/ptmx" >&5
12468echo $ECHO_N "checking for /dev/ptmx... $ECHO_C" >&6
12469 if test -e /dev/ptmx; then
12470 echo "$as_me:$LINENO: result: yes" >&5
12471echo "${ECHO_T}yes" >&6
12472
12473cat >>confdefs.h <<\_ACEOF
12474#define HAVE_DEV_PTMX 1
12475_ACEOF
12476
12477
12478cat >>confdefs.h <<\_ACEOF
12479#define CLONE_DEVICE "/dev/ptmx"
12480_ACEOF
12481
12482 have_clone=yes
12483 else
12484 echo "$as_me:$LINENO: result: no" >&5
12485echo "${ECHO_T}no" >&6
12486 fi
12487 ;;
12488esac
12489
12490if test x$ac_cv_func_getpt = xyes -o x$ac_cv_func_posix_openpt = xyes -o x$have_clone = xyes; then
12491 echo "$as_me:$LINENO: checking for UNIX98 ptys" >&5
12492echo $ECHO_N "checking for UNIX98 ptys... $ECHO_C" >&6
12493 cat >conftest.$ac_ext <<_ACEOF
12494/* confdefs.h. */
12495_ACEOF
12496cat confdefs.h >>conftest.$ac_ext
12497cat >>conftest.$ac_ext <<_ACEOF
12498/* end confdefs.h. */
12499#include <stdlib.h>
12500int
12501main ()
12502{
12503grantpt(0);unlockpt(0);ptsname(0);
12504 ;
12505 return 0;
12506}
12507_ACEOF
12508rm -f conftest.$ac_objext conftest$ac_exeext
12509if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12510 (eval $ac_link) 2>conftest.er1
12511 ac_status=$?
12512 grep -v '^ *+' conftest.er1 >conftest.err
12513 rm -f conftest.er1
12514 cat conftest.err >&5
12515 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12516 (exit $ac_status); } &&
12517 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12518 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12519 (eval $ac_try) 2>&5
12520 ac_status=$?
12521 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12522 (exit $ac_status); }; } &&
12523 { ac_try='test -s conftest$ac_exeext'
12524 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12525 (eval $ac_try) 2>&5
12526 ac_status=$?
12527 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12528 (exit $ac_status); }; }; then
12529 unix98_pty=yes
12530
12531cat >>confdefs.h <<\_ACEOF
12532#define UNIX98_PTY 1
12533_ACEOF
12534
12535 echo "$as_me:$LINENO: result: yes" >&5
12536echo "${ECHO_T}yes" >&6
12537else
12538 echo "$as_me: failed program was:" >&5
12539sed 's/^/| /' conftest.$ac_ext >&5
12540
12541echo "$as_me:$LINENO: result: no" >&5
12542echo "${ECHO_T}no" >&6
12543fi
12544rm -f conftest.err conftest.$ac_objext \
12545 conftest$ac_exeext conftest.$ac_ext
12546fi
12547
12548if test -z "$unix98_pty"; then
12549
12550for ac_func in openpty
12551do
12552as_ac_var=`echo "ac_cv_func_$ac_func" | $as_tr_sh`
12553echo "$as_me:$LINENO: checking for $ac_func" >&5
12554echo $ECHO_N "checking for $ac_func... $ECHO_C" >&6
12555if eval "test \"\${$as_ac_var+set}\" = set"; then
12556 echo $ECHO_N "(cached) $ECHO_C" >&6
12557else
12558 cat >conftest.$ac_ext <<_ACEOF
12559/* confdefs.h. */
12560_ACEOF
12561cat confdefs.h >>conftest.$ac_ext
12562cat >>conftest.$ac_ext <<_ACEOF
12563/* end confdefs.h. */
12564/* Define $ac_func to an innocuous variant, in case <limits.h> declares $ac_func.
12565 For example, HP-UX 11i <limits.h> declares gettimeofday. */
12566#define $ac_func innocuous_$ac_func
12567
12568/* System header to define __stub macros and hopefully few prototypes,
12569 which can conflict with char $ac_func (); below.
12570 Prefer <limits.h> to <assert.h> if __STDC__ is defined, since
12571 <limits.h> exists even on freestanding compilers. */
12572
12573#ifdef __STDC__
12574# include <limits.h>
12575#else
12576# include <assert.h>
12577#endif
12578
12579#undef $ac_func
12580
12581/* Override any gcc2 internal prototype to avoid an error. */
12582#ifdef __cplusplus
12583extern "C"
12584{
12585#endif
12586/* We use char because int might match the return type of a gcc2
12587 builtin and then its argument prototype would still apply. */
12588char $ac_func ();
12589/* The GNU C library defines this for functions which it implements
12590 to always fail with ENOSYS. Some functions are actually named
12591 something starting with __ and the normal name is an alias. */
12592#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
12593choke me
12594#else
12595char (*f) () = $ac_func;
12596#endif
12597#ifdef __cplusplus
12598}
12599#endif
12600
12601int
12602main ()
12603{
12604return f != $ac_func;
12605 ;
12606 return 0;
12607}
12608_ACEOF
12609rm -f conftest.$ac_objext conftest$ac_exeext
12610if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12611 (eval $ac_link) 2>conftest.er1
12612 ac_status=$?
12613 grep -v '^ *+' conftest.er1 >conftest.err
12614 rm -f conftest.er1
12615 cat conftest.err >&5
12616 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12617 (exit $ac_status); } &&
12618 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12619 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12620 (eval $ac_try) 2>&5
12621 ac_status=$?
12622 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12623 (exit $ac_status); }; } &&
12624 { ac_try='test -s conftest$ac_exeext'
12625 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12626 (eval $ac_try) 2>&5
12627 ac_status=$?
12628 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12629 (exit $ac_status); }; }; then
12630 eval "$as_ac_var=yes"
12631else
12632 echo "$as_me: failed program was:" >&5
12633sed 's/^/| /' conftest.$ac_ext >&5
12634
12635eval "$as_ac_var=no"
12636fi
12637rm -f conftest.err conftest.$ac_objext \
12638 conftest$ac_exeext conftest.$ac_ext
12639fi
12640echo "$as_me:$LINENO: result: `eval echo '${'$as_ac_var'}'`" >&5
12641echo "${ECHO_T}`eval echo '${'$as_ac_var'}'`" >&6
12642if test `eval echo '${'$as_ac_var'}'` = yes; then
12643 cat >>confdefs.h <<_ACEOF
12644#define `echo "HAVE_$ac_func" | $as_tr_cpp` 1
12645_ACEOF
12646
12647else
12648 echo "$as_me:$LINENO: checking for openpty in -lutil" >&5
12649echo $ECHO_N "checking for openpty in -lutil... $ECHO_C" >&6
12650if test "${ac_cv_lib_util_openpty+set}" = set; then
12651 echo $ECHO_N "(cached) $ECHO_C" >&6
12652else
12653 ac_check_lib_save_LIBS=$LIBS
12654LIBS="-lutil $LIBS"
12655cat >conftest.$ac_ext <<_ACEOF
12656/* confdefs.h. */
12657_ACEOF
12658cat confdefs.h >>conftest.$ac_ext
12659cat >>conftest.$ac_ext <<_ACEOF
12660/* end confdefs.h. */
12661
12662/* Override any gcc2 internal prototype to avoid an error. */
12663#ifdef __cplusplus
12664extern "C"
12665#endif
12666/* We use char because int might match the return type of a gcc2
12667 builtin and then its argument prototype would still apply. */
12668char openpty ();
12669int
12670main ()
12671{
12672openpty ();
12673 ;
12674 return 0;
12675}
12676_ACEOF
12677rm -f conftest.$ac_objext conftest$ac_exeext
12678if { (eval echo "$as_me:$LINENO: \"$ac_link\"") >&5
12679 (eval $ac_link) 2>conftest.er1
12680 ac_status=$?
12681 grep -v '^ *+' conftest.er1 >conftest.err
12682 rm -f conftest.er1
12683 cat conftest.err >&5
12684 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12685 (exit $ac_status); } &&
12686 { ac_try='test -z "$ac_cxx_werror_flag" || test ! -s conftest.err'
12687 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12688 (eval $ac_try) 2>&5
12689 ac_status=$?
12690 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12691 (exit $ac_status); }; } &&
12692 { ac_try='test -s conftest$ac_exeext'
12693 { (eval echo "$as_me:$LINENO: \"$ac_try\"") >&5
12694 (eval $ac_try) 2>&5
12695 ac_status=$?
12696 echo "$as_me:$LINENO: \$? = $ac_status" >&5
12697 (exit $ac_status); }; }; then
12698 ac_cv_lib_util_openpty=yes
12699else
12700 echo "$as_me: failed program was:" >&5
12701sed 's/^/| /' conftest.$ac_ext >&5
12702
12703ac_cv_lib_util_openpty=no
12704fi
12705rm -f conftest.err conftest.$ac_objext \
12706 conftest$ac_exeext conftest.$ac_ext
12707LIBS=$ac_check_lib_save_LIBS
12708fi
12709echo "$as_me:$LINENO: result: $ac_cv_lib_util_openpty" >&5
12710echo "${ECHO_T}$ac_cv_lib_util_openpty" >&6
12711if test $ac_cv_lib_util_openpty = yes; then
12712 cat >>confdefs.h <<\_ACEOF
12713#define HAVE_OPENPTY 1
12714_ACEOF
12715 LIBS="$LIBS -lutil"
12716fi
12717
12718fi
12719done
12720
12721fi
12722
10524 12723
10525if test x$support_xft = xyes; then 12724if test x$support_xft = xyes; then
10526 # Extract the first word of "pkg-config", so it can be a program name with args. 12725 # Extract the first word of "pkg-config", so it can be a program name with args.
10527set dummy pkg-config; ac_word=$2 12726set dummy pkg-config; ac_word=$2
10528echo "$as_me:$LINENO: checking for $ac_word" >&5 12727echo "$as_me:$LINENO: checking for $ac_word" >&5

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines