Various fixes for AIX 4.1

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@186 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Unknown User d91-jda
1995-10-28 18:20:04 +00:00
parent 97f3c143c4
commit 1d61424ff6
5 changed files with 47 additions and 42 deletions

View File

@@ -60,6 +60,9 @@
/* Used with login -p */ /* Used with login -p */
#undef LOGIN_ARGS #undef LOGIN_ARGS
/* Define if you have setupterm() */
#undef HAVE_SETUPTERM
/* */ /* */
#undef STREAMSPTY #undef STREAMSPTY

View File

@@ -41,6 +41,9 @@
/* */ /* */
#undef OLD_ENVIRON #undef OLD_ENVIRON
/* Define if you have setupterm() */
#undef HAVE_SETUPTERM
/* */ /* */
#undef STREAMSPTY #undef STREAMSPTY

68
appl/telnet/configure vendored
View File

@@ -870,7 +870,7 @@ fi
done done
for ac_func in tgetent for ac_func in tgetent setupterm
do do
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 echo $ac_n "checking for $ac_func""... $ac_c" 1>&6
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
@@ -921,6 +921,7 @@ else
fi fi
done done
if test $ac_cv_func_tgetent = no; then if test $ac_cv_func_tgetent = no; then
# tgetent is not in the default libraries. See if it's in some other. # tgetent is not in the default libraries. See if it's in some other.
for lib in termcap; do for lib in termcap; do
@@ -931,7 +932,7 @@ else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-l$lib $LIBS" LIBS="-l$lib $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 935 "configure" #line 936 "configure"
#include "confdefs.h" #include "confdefs.h"
int main() { return 0; } int main() { return 0; }
@@ -964,57 +965,48 @@ fi
done done
fi fi
for ac_func in setupterm if test $ac_cv_func_setupterm = no; then
do # setupterm is not in the default libraries. See if it's in some other.
echo $ac_n "checking for $ac_func""... $ac_c" 1>&6 for lib in curses; do
if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then echo $ac_n "checking for -l$lib""... $ac_c" 1>&6
if eval "test \"`echo '$''{'ac_cv_lib_$lib'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF ac_save_LIBS="$LIBS"
#line 975 "configure" LIBS="-l$lib $LIBS"
cat > conftest.$ac_ext <<EOF
#line 979 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */
#include <assert.h>
/* Override any gcc2 internal prototype to avoid an error. */
char $ac_func();
int main() { return 0; } int main() { return 0; }
int t() { int t() {
setupterm()
/* The GNU C library defines this for functions which it implements
to always fail with ENOSYS. Some functions are actually named
something starting with __ and the normal name is an alias. */
#if defined (__stub_$ac_func) || defined (__stub___$ac_func)
choke me
#else
$ac_func();
#endif
; return 0; } ; return 0; }
EOF EOF
if eval $ac_link; then if eval $ac_link; then
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_$ac_func=yes" eval "ac_cv_lib_$lib=yes"
else else
rm -rf conftest* rm -rf conftest*
eval "ac_cv_func_$ac_func=no" eval "ac_cv_lib_$lib=no"
fi fi
rm -f conftest* rm -f conftest*
LIBS="$ac_save_LIBS"
fi fi
if eval "test \"`echo '$ac_cv_func_'$ac_func`\" = yes"; then if eval "test \"`echo '$ac_cv_lib_'$lib`\" = yes"; then
echo "$ac_t""yes" 1>&6 echo "$ac_t""yes" 1>&6
ac_tr_func=HAVE_`echo $ac_func | tr '[a-z]' '[A-Z]'` cat >> confdefs.h <<\EOF
cat >> confdefs.h <<EOF #define HAVE_SETUPTERM 1
#define $ac_tr_func 1
EOF EOF
LIBS="$LIBS -l$lib"; break
else else
echo "$ac_t""no" 1>&6 echo "$ac_t""no" 1>&6
fi fi
done
done
fi
# these two are mainly here for solaris # these two are mainly here for solaris
@@ -1025,7 +1017,7 @@ if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1029 "configure" #line 1021 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */ which can conflict with char $ac_func(); below. */
@@ -1077,7 +1069,7 @@ else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lsocket $LIBS" LIBS="-lsocket $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1081 "configure" #line 1073 "configure"
#include "confdefs.h" #include "confdefs.h"
int main() { return 0; } int main() { return 0; }
@@ -1117,7 +1109,7 @@ if eval "test \"`echo '$''{'ac_cv_func_$ac_func'+set}'`\" = set"; then
echo $ac_n "(cached) $ac_c" 1>&6 echo $ac_n "(cached) $ac_c" 1>&6
else else
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1121 "configure" #line 1113 "configure"
#include "confdefs.h" #include "confdefs.h"
/* System header to define __stub macros and hopefully few prototypes, /* System header to define __stub macros and hopefully few prototypes,
which can conflict with char $ac_func(); below. */ which can conflict with char $ac_func(); below. */
@@ -1169,7 +1161,7 @@ else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lnsl $LIBS" LIBS="-lnsl $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1173 "configure" #line 1165 "configure"
#include "confdefs.h" #include "confdefs.h"
int main() { return 0; } int main() { return 0; }
@@ -1210,7 +1202,7 @@ else
ac_save_LIBS="$LIBS" ac_save_LIBS="$LIBS"
LIBS="-lutil $LIBS" LIBS="-lutil $LIBS"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1214 "configure" #line 1206 "configure"
#include "confdefs.h" #include "confdefs.h"
int main() { return 0; } int main() { return 0; }
@@ -1260,7 +1252,7 @@ else
# On the NeXT, cc -E runs the code through the compiler's parser, # On the NeXT, cc -E runs the code through the compiler's parser,
# not just through cpp. # not just through cpp.
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1264 "configure" #line 1256 "configure"
#include "confdefs.h" #include "confdefs.h"
#include <assert.h> #include <assert.h>
Syntax Error Syntax Error
@@ -1274,7 +1266,7 @@ else
rm -rf conftest* rm -rf conftest*
CPP="${CC-cc} -E -traditional-cpp" CPP="${CC-cc} -E -traditional-cpp"
cat > conftest.$ac_ext <<EOF cat > conftest.$ac_ext <<EOF
#line 1278 "configure" #line 1270 "configure"
#include "confdefs.h" #include "confdefs.h"
#include <assert.h> #include <assert.h>
Syntax Error Syntax Error

View File

@@ -148,7 +148,8 @@ AC_REPLACE_FUNCS(getent herror memmove setenv strdup strerror)
AC_CHECK_FUNCS(cgetent uname vfork vhangup) AC_CHECK_FUNCS(cgetent uname vfork vhangup)
AC_CHECK_FUNCS(tgetent) AC_CHECK_FUNCS(tgetent setupterm)
if test $ac_cv_func_tgetent = no; then if test $ac_cv_func_tgetent = no; then
# tgetent is not in the default libraries. See if it's in some other. # tgetent is not in the default libraries. See if it's in some other.
for lib in termcap; do for lib in termcap; do
@@ -157,7 +158,13 @@ if test $ac_cv_func_tgetent = no; then
done done
fi fi
AC_CHECK_FUNCS(setupterm) if test $ac_cv_func_setupterm = no; then
# setupterm is not in the default libraries. See if it's in some other.
for lib in curses; do
AC_CHECK_LIB($lib, setupterm, [AC_DEFINE(HAVE_SETUPTERM)
LIBS="$LIBS -l$lib"; break])
done
fi
# these two are mainly here for solaris # these two are mainly here for solaris

View File

@@ -101,7 +101,7 @@ extern struct sysv sysv;
#include <sys/proc.h> #include <sys/proc.h>
#undef SE #undef SE
#endif #endif
#if !(defined(__sgi) || defined(__linux)) #if !(defined(__sgi) || defined(__linux) || defined(_AIX))
#include <sys/tty.h> #include <sys/tty.h>
#endif #endif
#ifdef t_erase #ifdef t_erase
@@ -1362,7 +1362,7 @@ login_tty(t)
* setsid() call above may have set our pgrp, so clear * setsid() call above may have set our pgrp, so clear
* it out before opening the tty... * it out before opening the tty...
*/ */
# if defined(SOLARIS) || defined(__hpux) || defined(__sgi) # if defined(SOLARIS) || defined(__hpux) || defined(__sgi) || defined(_AIX)
(void) setpgrp(); (void) setpgrp();
# else # else
(void) setpgrp(0, 0); (void) setpgrp(0, 0);