1 diff -ur zsh-4.2.5/configure.ac zsh-4.2.5.new/configure.ac
2 --- zsh-4.2.5/configure.ac 2005-04-04 09:48:58.000000000 +0000
3 +++ zsh-4.2.5.new/configure.ac 2005-04-12 08:50:59.871181848 +0000
8 -dnl if found tcsetpgrp, test to see if it actually works
9 -dnl for instance, BeOS R4.51 does not support it yet
11 -AH_TEMPLATE([BROKEN_TCSETPGRP],
12 -[Define to 1 if tcsetpgrp() doesn't work, ie BeOS R4.51.])
13 -AC_ARG_WITH(tcsetpgrp,
14 -[ --with-tcsetpgrp assumes that tcsetpgrp() exists and works correctly],[
16 - xyes) zsh_working_tcsetpgrp=yes;;
17 - xno) zsh_working_tcsetpgrp=no;;
18 - *) AC_ERROR([please use --with-tcsetpgrp=yes or --with-tcsetpgrp=no]);;
19 -esac],[zsh_working_tcsetpgrp=check])
20 -if test "x$ac_cv_func_tcsetpgrp" = xyes; then
21 -case "x$zsh_working_tcsetpgrp" in
23 - ( trap "" SIGTTOU > /dev/null 2>&1 ) && trap "" SIGTTOU > /dev/null 2>&1
24 - AC_CACHE_CHECK(if tcsetpgrp() actually works,
25 - zsh_cv_sys_tcsetpgrp,
27 -#include <sys/types.h>
33 - fd=open("/dev/tty", O_RDWR);
34 - if (fd < 0) exit(2);
35 - ret=tcsetpgrp(fd, tcgetpgrp(fd));
36 - if (ret < 0) exit(1);
40 - zsh_cv_sys_tcsetpgrp=yes, [
42 - 1) zsh_cv_sys_tcsetpgrp=no;;
43 - 2) zsh_cv_sys_tcsetpgrp=notty;;
44 - *) zsh_cv_sys_tcsetpgrp=error;;
46 - ], zsh_cv_sys_tcsetpgrp=yes)])
47 - case "x$zsh_cv_sys_tcsetpgrp" in
48 - xno) AC_DEFINE(BROKEN_TCSETPGRP);;
50 - xnotty) AC_MSG_ERROR([no controlling tty
51 -Try running configure with --with-tcsetpgrp or --without-tcsetpgrp]);;
52 - *) AC_MSG_ERROR([unexpected return status]);;
54 - ( trap - SIGTTOU > /dev/null 2>&1 ) && trap - SIGTTOU > /dev/null 2>&1
57 - xno) AC_DEFINE(BROKEN_TCSETPGRP);;
58 - *) AC_MSG_ERROR([unexpected value zsh_working_tcsetpgrp=$zsh_working_tcsetpgrp]);;
63 dnl test for faked getpwnam() entry, ie a single entry returned for any username
64 dnl for instance, BeOS R4.51 is not multiuser yet, and fakes getpwnam()
65 dnl test by looking up two usernames that shouldn't succeed, and compare entry