Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

IO:Tty installation in cygwin fails. stuck at "trying to open /dev/tty1."

by ericfons (Initiate)
on Nov 14, 2011 at 23:24 UTC ( #938045=perlquestion: print w/ replies, xml ) Need Help??
ericfons has asked for the wisdom of the Perl Monks concerning the following question:

When I try to install IO::Tty in cygwin environment, it gets stuck at "trying to open /dev/tty?..." each time.

The first time I tried it got stuck at:

"trying to open /dev/tty1...".

When I aborted, and retried, it got stuck at:

"trying to open /dev/tty2..."

Each time I abort and retry the tty number goes up - tty3, tty4 etc.

(see log snippet at the end)

Given my limited knowledge of unix, I tried this:

ln -s /dev/stdout /dev/tty5

where 5 was the next tty number that it would get hung at duing the next attempt. It still got hung at tty5. In other words the symbolic link did not help.

I am running the latest version of cygwin v1.7.9. I need to install IO::Tty so that perl module Expect can be installed.

I'm really out of ideas. Your help will be much appreciated.

: Writing IO::Tty::Constant.pm... DEFINE = -DHAVE_CYGWIN -DHAVE_DEV_PTMX -DHAVE_GRANTPT -DHAVE_OPENPTY - +DHAVE_POSIX_OPENPT -DHAVE_PTSNAME -DHAVE_PTY_H -DHAVE_SIGACTION -DHAV +E_STRLCPY -DHAVE_TERMIOS_H -DHAVE_TERMIO_H -DHAVE_TTYNAME -DHAVE_UNLO +CKPT Checking if your kit is complete... Looks good Writing Makefile for IO::Tty cp Tty.pm blib/lib/IO/Tty.pm cp Tty/Constant.pm blib/lib/IO/Tty/Constant.pm cp Pty.pm blib/lib/IO/Pty.pm /usr/bin/perl.exe /usr/lib/perl5/5.10/ExtUtils/xsubpp -typemap /usr/l +ib/perl5/5.10/ExtUtils/typemap Tty.xs > Tty.xsc && mv Tty.xsc Tty.c gcc -c -DPERL_USE_SAFE_PUTENV -U__STRICT_ANSI__ -fno-strict-aliasing + -pipe -fstack-protector -I/usr/local/include -DUSEIMPORTLIB -O3 -D +VERSION=\"1.08\" -DXS_VERSION=\"1.08\" "-I/usr/lib/perl5/5.10/i686-c +ygwin/CORE" -DHAVE_CYGWIN -DHAVE_DEV_PTMX -DHAVE_GRANTPT -DHAVE_OPEN +PTY -DHAVE_POSIX_OPENPT -DHAVE_PTSNAME -DHAVE_PTY_H -DHAVE_SIGACTION +-DHAVE_STRLCPY -DHAVE_TERMIOS_H -DHAVE_TERMIO_H -DHAVE_TTYNAME -DHAVE +_UNLOCKPT Tty.c rm -f blib/arch/auto/IO/Tty/Tty.dll g++ --shared -Wl,--enable-auto-import -Wl,--export-all-symbols -Wl,- +-stack,8388608 -Wl,--enable-auto-image-base -L/usr/local/lib -fstack- +protector Tty.o -o blib/arch/auto/IO/Tty/Tty.dll \ /usr/lib/perl5/5.10/i686-cygwin/CORE/cygperl5_10.dll -lutil + \ chmod 755 blib/arch/auto/IO/Tty/Tty.dll test -s Tty.bs && cp Tty.bs blib/arch/auto/IO/Tty/Tty.bs && \ chmod 644 blib/arch/auto/IO/Tty/Tty.bs Manifying blib/man3/IO.Tty.Constant.3pm Manifying blib/man3/IO.Tty.3pm Manifying blib/man3/IO.Pty.3pm RGIERSIG/IO-Tty-1.08.tar.gz make -- OK Running make test PERL_DL_NONLAZY=1 /usr/bin/perl.exe "-Iblib/lib" "-Iblib/arch" test.pl 1..4 Configuration: -DHAVE_CYGWIN -DHAVE_DEV_PTMX -DHAVE_GRANTPT -DHAVE_OPE +NPTY -DHAVE_POSIX_OPENPT -DHAVE_PTSNAME -DHAVE_PTY_H -DHAVE_SIGACTION + -DHAVE_STRLCPY -DHAVE_TERMIOS_H -DHAVE_TERMIO_H -DHAVE_TTYNAME -DHAV +E_UNLOCKPT Checking for appropriate ioctls: Checking that returned fd's don't clash with stdin/out/err... trying posix_openpt()... trying grantpt()... trying unlockpt()... trying ptsname()... trying to open /dev/tty4...

Comment on IO:Tty installation in cygwin fails. stuck at "trying to open /dev/tty1."
Select or Download Code
Replies are listed 'Oldest First'.
Re: IO:Tty installation in cygwin fails. stuck at "trying to open /dev/tty1."
by quester (Vicar) on Nov 15, 2011 at 07:52 UTC

    Based on a comment (Re^3: IO::Pty with Cygwin - can't install (by azredwing), in thread IO::Pty with Cygwin - can't install (also by azredwing) it looks like Expect.pm will work even if that particular test in IO::Tty fails.

    YMMV, but you could try this and see if it helps:

    # cpan cpan[1]> notest install IO::Tty cpan[2]> install Expect

    If all goes well, Expect will pass its tests and install. It worked for me (Windows Vista, Cygwin 1.7.9-1.)

    There is also a more drastic form of install, "force install IO::Tty", which will run the test but attempts to continue even if there are failures. Since the test hangs, you will have to control-C out of the test so the install will complete.

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://938045]
Approved by keszler
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others cooling their heels in the Monastery: (14)
As of 2015-07-07 16:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (92 votes), past polls