[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: portable openpty, forkpty

From: Bruno Haible
Subject: Re: portable openpty, forkpty
Date: Sun, 28 Mar 2010 12:16:02 +0100
User-agent: KMail/1.9.9

Hi Simon,

Thanks for testing.
> The forkpty code builds fine as a part of InetUtils on Mac OS X.  I
> tried the gnulib self-checks for forkpty, but they failed:
> Making check in gltests
> make  check-recursive
> make  check-TESTS
> PASS: test-alignof
> PASS: test-errno
> PASS: test-fcntl-h
> PASS: test-fcntl-h-c++
> forkpty returned -1
> FAIL: test-forkpty
> openpty returned -1
> FAIL: test-login_tty
> openpty returned -1
> FAIL: test-openpty
> PASS: test-pty-c++
> PASS: test-stddef
> PASS: test-stdint
> PASS: test-sys_ioctl
> PASS: test-sys_ioctl-c++
> PASS: test-sys_socket
> PASS: test-sys_socket-c++
> PASS: test-unistd
> PASS: test-unistd-c++
> PASS: test-wchar
> PASS: test-wchar-c++
> ====================
> 3 of 18 tests failed
> ====================
> This is from a package created with './gnulib-tool --dir m
> --create-testdir --with-tests forkpty'

The only version of MacOS X I have access to is 10.5, and on this
system it works fine, both with the system-provided 'openpty'
   ./configure CPPFLAGS=-Wall
as well as with the gnulib replacements
   ac_cv_func_openpty=no \
   ac_cv_func_forkpty=no \
   ac_cv_func_login_tty=no \
   ac_cv_have_decl_openpty=no \
   ac_cv_have_decl_forkpty=no \
   ac_cv_have_decl_login_tty=no \
   ./configure CPPFLAGS=-Wall

Can you check why openpty and login_tty fail? The tests are written
in a way that can easily be single-stepped. (To build for debugging and
single-stepping on MacOS X, use CFLAGS=-ggdb, then you can debug with

The implementation of openpty on a particular platform is quite easy
to understand, once you stepped through it. It's only the #ifs which
are complicated.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]