Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Module Problems

by waiterm (Acolyte)
on Jan 26, 2004 at 19:12 UTC ( [id://324228]=perlquestion: print w/replies, xml ) Need Help??

waiterm has asked for the wisdom of the Perl Monks concerning the following question:

I'm trying to install Net::SCP::Expect, which uses IO::Tty, IO::Pty and Expect as prerequisites.
However when I try and install Tty via CPAN the install is failing with the following error messages (makefile works, but the nmake doesn't):

Tty.xs(94) : fatal error C1083: Cannot open include file: 'unistd.h': No such file or directory
NMAKE : fatal error U1077: 'cl' : return code '0x2' Stop.

Replies are listed 'Best First'.
Re: Module Problems
by bart (Canon) on Jan 26, 2004 at 19:52 UTC
    PodMaster said in the Chatterbox the other day, that IO::Tty simply doesn't work on Windows — or with just limited success under Cygwin. Tough luck, I'm afraid, it just won't work. You'll have to wait for PodMaster to return to give you more details.
Re: Module Problems
by kutsu (Priest) on Jan 26, 2004 at 19:23 UTC

    This tutorial gives the basics on how to install a module. As for nmake have you added it to your path?

    Also microsoft gives this info on Visual C++, don't know if it will help

    "Cogito cogito ergo cogito sum - I think that I think, therefore I think that I am." Ambrose Bierce

Re: Module Problems
by Limbic~Region (Chancellor) on Jan 26, 2004 at 19:40 UTC
    waiterm,
    Getting Expect, which requires IO::Tty and IO::Pty to install in a Win32 environment is not easy, let alone straight forward. Just from looking at the FAQ it says it is only possible using Cygwin. I had moderate success. I believe the issue is the Win32 concept of a tty. What are your requirements as possibly there is another solution?

    Cheers - L~R

      I'm basically aiming to automate the SCP process without having the need for someone to enter a pssword. I run a lot of automated programs and at the moment I'm having to SCP them all manually to the remote server.

      It's basically so that if I go away or am busy (such as next week to Florida!!) Then I simply want my server to run the updates automatically in my absense.
        waiterm,
        In my previous place of employment, I wrote numerous shell scripts that do what you want without Expect or Expect. I accomplished this by using key based authentication instead of passwords. I am sure the same would be possible with a batch file. If you need help creating and configuring key based authentication, you can look at http://www.openssh.org or reply here and I will post step by step instructions.

        Cheers - L~R

Re: Module Problems
by CountZero (Bishop) on Jan 26, 2004 at 19:36 UTC
    When you download the nmake15.exe, you must run it: it will create three other files (nmake.exe, nmake.err and a third unimportant read-me type file). Put nmake.exe and nmake.err somewhere in your path.

    Then you must edit the config.pm file in perl/lib/CPAN so that the Config-hash has something like 'make' => q[C:\WINDOWS\system32\nmake.exe], (of course you would edit that to show where your nmake.exe is). I'm not entirely sure, but I think that when you put the full path to nmake.exe in the hash, nmake.exe does not have to be in your path. If you like to live dangerously, you can just put 'make' => q[nmake.exe], in the Config-hash.

    CountZero

    "If you have four groups working on a compiler, you'll get a 4-pass compiler." - Conway's Law

Re: Module Problems
by jacques (Priest) on Jan 26, 2004 at 19:31 UTC
    You're using NMAKE, so you are likely on $Windoze. Try using a PPM from Activestate or one of the local repositories here at PerlMonks. The first thing you should do is to see if PPM is on your system. Type PPM at the DOS prompt and see what happens.
Re: Module Problems
by Anonymous Monk on Jan 27, 2004 at 00:44 UTC
    You should try psftp, it should come with putty. You can write automation scripts with perl

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others cooling their heels in the Monastery: (5)
As of 2024-04-20 00:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found