PTY

Roumen Petrov roumen.petrov at skalasoft.com
Wed Jan 31 22:25:20 EST 2001


environment
1)compiler: cc -v
Reading specs from /usr/lib/gcc-lib/i386-slackware-linux/2.95.2/specs
gcc version 2.95.2 19991024 (release)

2)openssh: CVS from 31 jan 2001

3)libc:   GNU libc 2.2.1

output form make pty.o is:
#make pty.o
gcc -g -O2 -Wall -I/usr/local/ssl/include -I. -I. -DETCDIR=\"/etc\" 
-D_PATH_SSH_PROGRAM=\"/usr/bin/ssh\" 
-D_PATH_SSH_ASKPASS_DEFAULT=\"/usr/libexec/ssh-askpass\" -DHAVE_CONFIG_H -c pty.c
pty.c: In function `pty_allocate':
pty.c:55: warning: implicit declaration of function `openpty'

This is old warning but today i have time to investigate.

GNU libc has pty.h and openssh has pty.h

Problem is that system ( from libc ) pty.h is never included, but !!! OpenSSH 
work well good with openpty method.

how to stop this warning and to include pty.h from libc :

1) to rename pty.X to ssh-pty.X plus changes from #include "pty.h" to #include 
"ssh-pty.h" in header/source files
2) to put pty.h in subfolder XXXssh and use #include "XXXssh/pty.h" in 
header/source files
3) to add in configure.in line:
......
...*-*-linux*)
        CPPFLAGS="-I/usr/include $CPPFLAGS"
......






More information about the openssh-unix-dev mailing list