[8768] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 2384 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Apr 22 13:27:32 1998

Date: Wed, 22 Apr 98 10:20:24 -0700
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)

Perl-Users Digest           Wed, 22 Apr 1998     Volume: 8 Number: 2384

Today's topics:
        Netscape Perl?  Beginner question <unk@webcom.com>
    Re: Neutering exit in eval (Steffen Beyer)
        new to perl, can't rcp to copy file to remote machine <dmwaff@erols.com>
    Re: new to perl, can't rcp to copy file to remote machi <sneaker@earthling.net>
        Newbie Perl and Form Output <trogers@patriot.net>
    Re: Newbie Perl and Form Output <rdschramm@earthlink.net>
    Re: Newbie Question re:mkdir for nested directories <rootbeer@teleport.com>
        newbie trying to close off a pipe <dbae@maths.warwick.ac.uk>
    Re: newbie's question on file IO in PERL (Petr Prikryl)
        OLE in AS port vs OLE in GS port <davidc@selectst.com>
        on fork <jong@salt2.med.harvard.edu>
    Re: on fork <quentin@jihad.amd.com>
        Packlist -- I'm gonna blow it away <jdporter@min.net>
        Parser works sometimes (Jay Fayloga)
    Re: Parser works sometimes <tchrist@mox.perl.com>
    Re: Parser works sometimes (Abigail)
    Re: Parser works sometimes (Abigail)
    Re: Password changing under Solaris <sneaker@earthling.net>
    Re: Password changing under Solaris <sneaker@earthling.net>
    Re: Password changing under Solaris (Jason Gloudon)
    Re: Password changing under Solaris <sneaker@earthling.net>
    Re: Pattern Matching on HighBit Characters <hsommer@micro.ti.com>
    Re: Perl 5.004_04 will not compile under Linux <dfetter@shell4.ba.best.com>
        Perl and IIS 4.0 <adrianr@rmitpublishing.com.au>
        Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Tue, 21 Apr 1998 01:34:23 -0700
From: Unk <unk@webcom.com>
Subject: Netscape Perl?  Beginner question
Message-Id: <353C5A0F.43AF@webcom.com>

I'm trying to get Perl to run in Netscape, on a local file on my own
machine.

Netscape says file is type "application/x-perl" and then it doesn't know
what plug in to load.

I have perl installed on my machine (a PC with 95) and I put a copy of
Perl.exe in the directory "/usr/local/bin" where my Perl script says it
is.

What else do I need to do to get the damn thing working?

My e-mail return address is good, please include it in your response.

Thank you,
Bill Unakern


------------------------------

Date: 18 Apr 1998 07:09:39 GMT
From: sb@engelschall.com (Steffen Beyer)
Subject: Re: Neutering exit in eval
Message-Id: <6h9jjj$mj5$1@en1.engelschall.com>

Jack Applin <neutron@fc.hp.com> wrote:

> I have some user Perl code (read from a file) that I want to execute
> many times, with $_ set to something different each time.
> It's similar to this:

> 	$usercode = <USERCODE>;
        $usercode =~ s/\bexit\b/die/g;
> 	for $_ (@messages) {
> 		eval $usercode;		# Process each message
> 	}

> I can use $SIG{__DIE__} to intercept the user code if it does a die.
> What can I do if it does an exit?  Using END {} is not convenient,
> because I want to just keep going in the loop.

See above.

HTH.

Yours,
-- 
     Steffen Beyer <sb@engelschall.com>
  Feel free to visit my download area with free software at
     http://www.engelschall.com/u/sb/download/


------------------------------

Date: Tue, 21 Apr 1998 20:44:52 -0400
From: "David Waffen" <dmwaff@erols.com>
Subject: new to perl, can't rcp to copy file to remote machine
Message-Id: <6hjeel$mqs$1@winter.news.erols.com>

I have been working on a Unix remove user script.
Nutshell:
1.script creates a log file (.RM_USER.LOG) in /tmp on machine "A"
2.log must be rcp'ed to the users home directory located on a server at a
remote site.  machine "B"
3.then tar up user home via rsh from "A"
4.rcp back the tar home to a directory on my server "A" where it is held and
marked for deletion at a later date.

My machine "A" is listed in root's /.rhosts file and I am running the script
as "root".
>From the command line it works fine, BUT in the script the rcp call works
part way.
Meaning the script grabs the log file and seems to just "touch" the file in
the home.  IT HAS zero size.  Non of the contents are transferred.  Open it,
its empty.  I have tried it with and without a log file existing on "B".

syntax used:
system("rcp /tmp/.rm_user.log SERVER:/Users/<user>");
ALSO
@array = ("rcp /tmp/.rm_user.log SERVER:/Users/<user>");
system(@array);

HELP PLEASE.
david.waffen@mci.com or dmwaff@erols.com




------------------------------

Date: Wed, 22 Apr 1998 01:03:28 GMT
From: Bill 'Sneex' Jones <sneaker@earthling.net>
Subject: Re: new to perl, can't rcp to copy file to remote machine
Message-Id: <353D4043.48FB9047@earthling.net>

David Waffen wrote:

> I have been working on a Unix remove user script.
> Nutshell:
> 1.script creates a log file (.RM_USER.LOG) in /tmp on machine "A"
> 2.log must be rcp'ed to the users home directory located on a server at a
> remote site.  machine "B"
> 3.then tar up user home via rsh from "A"
> 4.rcp back the tar home to a directory on my server "A" where it is held and
> marked for deletion at a later date.
>

 Does it HAVE to be done that way?   Another approach:

I have a script which is driven by the Personnel department, they are on a
S/390 with VM and PROFS/OV, etc.  When they add or remove a faculty and/or
staff member the S/390 e-mails (securely) a special userid on a E3000 (which is
really the perl script in disguise :-)  That script does the account creations
and deletions (including tarring/gzipping the user directories in case we need
them back, even after the user is gone.)  And stores them on an 11GB raid5
array for 6 months, then if the filestamp is > 6 months it deletes the .tgz
file for those which are out of date.

Remote copying seems cumbersome, don't you think?

2 Cents worth :-)
__________________________
Bill Jones...............|
Sneaker's Nest...........|
Chasecreek Systemhouse...|





------------------------------

Date: Sun, 19 Apr 1998 15:20:36 -0400
From: "Tim Rogers" <trogers@patriot.net>
Subject: Newbie Perl and Form Output
Message-Id: <6hdm0a$r08$1@washington.patriot.net>

I'm a newbie at using perl. I'm looking for a perl script that will output
the html and the form inputs as well. I tried modifying the mailto script
but it doesn't work, only the inputs are sent back. If anyone can help, or
point me to where I can find free scripts that can do this job I would
greatly appreciate the assistance.

Thanks,
Tim




------------------------------

Date: Sun, 19 Apr 1998 18:43:05 -0400
From: <rdschramm@earthlink.net>
Subject: Re: Newbie Perl and Form Output
Message-Id: <6hdupe$hql@chile.earthlink.net>

Check out the CGI module available at CPAN.  It does everything you could
possibly need as far as CGI and is well documented.

Tim Rogers wrote in message <6hdm0a$r08$1@washington.patriot.net>...
>I'm a newbie at using perl. I'm looking for a perl script that will output
>the html and the form inputs as well.




------------------------------

Date: Wed, 22 Apr 1998 00:40:54 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Laura Morgan <laura.morgan@itron.com>
Subject: Re: Newbie Question re:mkdir for nested directories
Message-Id: <Pine.GSO.3.96.980421173707.21174m-100000@user2.teleport.com>

On Tue, 21 Apr 1998, Laura Morgan wrote:

> Subject: Newbie Question re:mkdir for nested directories

Please check out this helpful information on choosing good subject
lines. It will be a big help to you in making it more likely that your
requests will be answered.

    http://www.perl.com/CPAN/authors/Dean_Roehrich/subjects.post

> I'm trying to use the mkdir command to create nested directories.  It
> only seems to work when I create one directory at a time down the tree. 

But there's a module which comes with Perl which will do this. Look for
the mkpath function in File::Path. Hope this helps!

-- 
Tom Phoenix       Perl Training and Hacking       Esperanto
Randal Schwartz Case:     http://www.rahul.net/jeffrey/ovs/



------------------------------

Date: Mon, 20 Apr 1998 17:26:09 +0100
From: David Epstein <dbae@maths.warwick.ac.uk>
Subject: newbie trying to close off a pipe
Message-Id: <353B7720.8F8B2DE3@maths.warwick.ac.uk>

Here is a fragment of code I'm trying to get to work

open(SENDMAIL,"|/usr/lib/sendmail -t") or die etc;
print SENDMAIL $various;
close SENDMAIL;# BUT it refuses to close.

What happens is that the close statement hangs. I assume (but don't
know) that this is because sendmail is busy on more important business,
and so the child created by the pipe is not returning.

If I delete SENDMAIL from the close statement, then the mail gets sent
as desired, but also all my other filehandles are closed at the same
time.

So my question is, how do I cut the child loose and say "You're on your
own now, kid"? If I was working interactively under tcsh, I would
suspend the
process and background it, and hope that would work.

There may be a sendmail flag which will do the job, but I'm trying to
learn perl, not sendmail, so I would welcome a general solution, which
would work
with commands other than sendmail.

David Epstein (welcomes answers direct to his email address because
there
is so much traffic on clpm that he would be likely to miss the answers).


------------------------------

Date: 20 Apr 1998 16:50:12 GMT
From: prikryl@dcse.fee.vutbr.cz (Petr Prikryl)
Subject: Re: newbie's question on file IO in PERL
Message-Id: <6hfuc4$e95$2@boco.fee.vutbr.cz>

Eric Bohlman (ebohlman@netcom.com) wrote:
>Ravi Narayanan <ravi.narayanan@citicorp.com> wrote:
>: once i open a file in the input mode how do i assign a variable the
>: value of the input ?

>perldoc perlop, look in the section on file input operators.


You may start to experiment with:

    open INPUT, "< filename" or die "Cannot open <filename: $!";

    $str = <INPUT>;   # reads next line from INPUT file
    @all = <INPUT>;   # reads the rest of lines from INPUT 
                      # (the array context)
    close INPUT;

Petr

--
Petr Prikryl (prikryl@dcse.fee.vutbr.cz)   http://www.fee.vutbr.cz/~prikryl/
TU of Brno, Dept. of Computer Sci. & Engineering;    tel. +420-(0)5-7275 218


------------------------------

Date: Mon, 20 Apr 1998 11:32:55 +1000
From: David Coldrick <davidc@selectst.com>
Subject: OLE in AS port vs OLE in GS port
Message-Id: <353AA5C6.D14D70C9@selectst.com>

Just installed Gurusamy Sarathy's port (based on 5.004_02) as a
potential replacement for the ActiveState port based on 5.003_07 that I
have been using. Having just read Advanced Perl Programming, I would
like to get access to Tk.

Problem is the differences in OLE support in the two versions: OLE
automation in the AS port works fine for me: the following snippet
displays a list of projects in SELECT Enterprise just fine:

use OLE;
my $np = 0;
$Projects = CreateObject OLE 'OMTE.Projects';
foreach $Project (keys %$Projects) {
    print ++$np, ", ", $Project->{"Title"}, ": ",
$Project->{"Directory"}, "\n";
    }

However, the version below - translated for the GS port - doesn't:

use Win32::OLE;
my $np = 0;
$Projects = Win32::OLE->new('OMTE.Projects');
foreach $Project (keys %$Projects) {
   print ++$np, ", ", $Project->{"Title"}, ": ",
$Project->{"Directory"}, "\n";
    }

It executes the foreach loop precisely once, with $Project having the
value undef.

The doc for the GS OLE interface quietly states:

"The Win32::OLE module uses the IDispatch interface exclusively. It is
not possible to access a custom OLE interface. OLE events and OCX's are
currently not supported."

Now, given my extensive OLE knowledge . . . NOT!, I haven't the foggiest
idea what the IDispatch interface is, but I suspect that this is my
problem.

Can anyone elaborate?

Regards,
David



------------------------------

Date: Mon, 20 Apr 1998 11:10:19 -0400
From: jong <jong@salt2.med.harvard.edu>
Subject: on fork
Message-Id: <353B655B.2FB1FB3E@salt2.med.harvard.edu>

Hi

Can anybody tell teach me more than the manual
level of fork(the detailed way how it works).

Also I wonder how  NT can make daemon processes.
Does it have fork ?

Cheers,

Jong


-- 

   Jong : A biology student
   Tel: 617-432-3675 (lab, I work very late, usually)
   Tel: 617-432-0503 (lab, computer room)
   Tel: 617-713-0990


------------------------------

Date: 20 Apr 1998 13:28:53 -0500
From: Quentin  Fennessy <quentin@jihad.amd.com>
Subject: Re: on fork
Message-Id: <ximra2se49m.fsf@jihad.amd.com>

>>>>> "Jong" == jong  <jong@salt2.med.harvard.edu> writes:

    Jong> Hi Can anybody tell teach me more than the manual level of
    Jong> fork(the detailed way how it works).

    Jong> Also I wonder how NT can make daemon processes.  Does it
    Jong> have fork ?

Jong- I suggest you read the Unix man page for fork
(man fork, or man -s 2 fork or man 2 fork).  Below is a snippet from
SunOS 5.5.1.  If you wish to understand further, excellent!
fork(2) is true Unix, and an excellent piece of OS design.

Deeper details are available in books such as 'The Magic Garden Explained'
(really!), 'The Design of the Unix Operating System', etc.

I do not know how NT creates processes, or daemons.  

fork(2)                   System Calls                    fork(2)

NAME
     fork, fork1 - create a new process

SYNOPSIS
     #include <sys/types.h>
     #include <unistd.h>

     pid_t fork(void);

     pid_t fork1(void);

MT-LEVEL
     fork() is Async-Signal-Safe

DESCRIPTION
     fork() and fork1() cause creation of a new process.  The new
     process (child process) is an exact copy of the calling pro-
     cess (parent process).  The child process inherits the  fol-
     lowing attributes from the parent process:

     o  real user ID, real group ID, effective user ID, effective
       group ID
     o  environment
     o  open file descriptors
     o  close-on-exec flags (see exec(2))
     o  signal handling  settings  (that  is,  SIG_DFL,  SIG_IGN,
       SIG_HOLD, function address)
     o  supplementary group IDs
     o  set-user-ID mode bit
     o  set-group-ID mode bit
     o  profiling on/off status
     o  nice value (see nice(2))
     o  scheduler class (see priocntl(2))
     o  all attached shared memory segments (see shmop(2))
     o  process group ID -- memory mappings (see mmap(2))
     o  session ID (see exit(2))
     o  current working directory
     o  root directory
     o  file mode creation mask (see umask(2))
     o  resource limits (see getrlimit(2))
     o  controlling terminal
     o  saved user ID and group ID

     Scheduling priority and any per-process  scheduling  parame-
     ters  that  are  specific to a given scheduling class may or
     may not be inherited according to the policy of that partic-
     ular  class  (see  priocntl(2)).   The child process differs
     from the parent process in the following ways:

     o  The child process has a unique process ID which does  not
       match any active process group ID.

     o  The child process has a different parent process ID (that
       is, the process ID of the parent process).

     o  The child process has its own copy of the  parent's  file
       descriptors  and  directory  streams.  Each of the child's
       file descriptors shares a common  file  pointer  with  the
       corresponding file descriptor of the parent.

-- 
Quentin Fennessy			AMD, Austin Texas
Secret hacker rule #11 - hackers read manuals


------------------------------

Date: Mon, 20 Apr 1998 19:25:55 GMT
From: John Porter <jdporter@min.net>
Subject: Packlist -- I'm gonna blow it away
Message-Id: <353BA2C5.6646@min.net>

Anyone have any expert advice on whether I absolutely should not
blow away the .packlist files?

Here's the sitch: we're gonna include the perl distribution in
our software installation. We're using InstallShield to manage
the installation (this is on NT).  InstallShield (I think)
balks at filenames that start with dot.  In the perl directory
structure there's a number of files named .packlist, which are
consulted when a package is uninstalled.  (They're create when
a package is installed.)  (Ooh, that's "package" NOT in the 
perl keyword sense.)

So: can I safely say "forget the .packlist files", and expect
that no one will try to uninstall any of those packages?
How catastrophic is it, generally, to not be able to uninstall
a package before installing a new version?

mille grazie,
John Porter


------------------------------

Date: Sun, 19 Apr 1998 20:47:38 -0700
From: no_spam@medianook.com (Jay Fayloga)
Subject: Parser works sometimes
Message-Id: <no_spam-1904982047390001@sf-pm15-1-193.dialup.slip.net>

Hello,

I'm stuck at a point where I thought I would ask for some help from others
out there. I have a parser that is trying to remove all HTML tags from a
page and give me a reasonable, nice, straight forward text page.

However, the part below isn't working as cleanly as I think it could.
First, seems to delete entire areas with complex HTML, such as nested
tables. Second, I think long pages give it some trouble. Any thoughts.


### BEGIN PARSING ###

# entire page sucked up into $content

# get rid of scripts first 
$content =~ s/<script(.*)\/script//ig; 
# get rid of comments 
$content =~ s/<!--(.*)-->//g; 
# get rid of all newline characters 
$content =~ s/\n//g; 
# get rid of all return characters
$content =~ s/\r//g;
# substitute a column cell with a newline 
$content =~ s/\<td\>/\n/ig;
# substitute a column row with a newline 
$content =~ s/<tr>/\n/ig; 
# put in two newlines at the end of a table 
$content =~ s/<\/table>/\n\n/ig; 
# put in two newlines at a paragraph 
$content =~ s/<p>/\n\n/ig; 
# put in a newline for a normal break 
$content =~ s/<br>/\n/ig; 
# get rid of the rest of the tags 
$content =~ s/<(.*)>//g;

### END PARSING ###

Thank you very much.

Jay Fayloga
jf@medianook.com

SPAM NOTICE
To reply to me personally, DO NOT reply to this message. Replies to the originating address are filtered to the trash with the rest of the spam. Send personal replies to my address above.


------------------------------

Date: 20 Apr 1998 04:05:57 GMT
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: Parser works sometimes
Message-Id: <6hehj5$d4e$2@csnews.cs.colorado.edu>

 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc, jf@medianook.com (Jay Fayloga), whose
address has been added to the spammage list, writes:

:I'm stuck at a point where I thought I would ask for some help from others
:out there. I have a parser that is trying to remove all HTML tags from a
:page and give me a reasonable, nice, straight forward text page.

The only way you can hope to do this is to abandon your regexp approach.
Even my striphtml program is imperfect, but it's much more complete
than yours.  You forget /s, for example.  But there's much more.

You have to be able to handle all of these cases:

    <IMG SRC = "foo.gif"
         ALT = "Flurp!">

    <IMG SRC = "foo.gif" ALT = "A > B">

    <!-- <A comment> -->

    <script>
	if (a<b && a>c) {
	    x = "</script>";
	} 
    </script>

    <# Just data #>

    <![INCLUDE [CDATA [ >>>>>>>>>>>> ]]>
    
    <!-- This section commented out.
        <B>You can't see me!</B>
    -->
         
    <!DOCTYPE  HTML PUBLIC "-//IETF//DTD HTML 2.0//EN"
      -- This is an annoying comment > --
    >

My guess is that you'll go nuts with these.  If you don't,
you're probably already crazy. :-)

Here's a very simple answer to this madness:

    use HTML::Parse;
    use HTML::FormatText;
    $plain_text = HTML::FormatText->new->format(parse_html($html_text));

Retrieve the LWP bundle from CPAN if you have't installed those
modules yet.  It will make you much happier.

--tom

    PS: Please don't spam Jay Fayloga <jf@medianook.com> even 
	if he does make it a pain in the ass to send him an
	answer to his question.

-- 
	Tom Christiansen	tchrist@jhereg.perl.com

    OK, enough hype.
            --Larry Wall in the perl man page 


------------------------------

Date: 20 Apr 1998 17:05:00 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: Parser works sometimes
Message-Id: <6hfv7s$4e2$1@client3.news.psi.net>

Tom Christiansen (tchrist@mox.perl.com) wrote on MDCXCIII September
MCMXCIII in <URL: news:6hehj5$d4e$2@csnews.cs.colorado.edu>:
++  [courtesy cc of this posting sent to cited author via email]
++ 
++ In comp.lang.perl.misc, jf@medianook.com (Jay Fayloga), whose
++ address has been added to the spammage list, writes:
++ 
++ :I'm stuck at a point where I thought I would ask for some help from others
++ :out there. I have a parser that is trying to remove all HTML tags from a
++ :page and give me a reasonable, nice, straight forward text page.
++ 
++ The only way you can hope to do this is to abandon your regexp approach.
++ Even my striphtml program is imperfect, but it's much more complete
++ than yours.  You forget /s, for example.  But there's much more.
++ 
++ You have to be able to handle all of these cases:
++ 
++     <script>
++ 	if (a<b && a>c) {
++ 	    x = "</script>";
++ 	} 
++     </script>

Well, this isn't correct HTML. SGML parsing rules are wacky.
SCRIPT has CDATA content, which means that '</' followed by 
what can be the start of a nametoken terminates the element.
Hence, the content of the about SCRIPT element is
    if (a<b && a>c) {
        x = "
followed by
             ";
    }
   </script>

Which is an error as there is no open element SCRIPT.

++     use HTML::Parse;

HTML::Parse won't do all of the above correctly :(



Abigail
-- 
perl -we '$_ = q ;4a75737420616e6f74686572205065726c204861636b65720as;;
          for (s;s;s;s;s;s;s;s;s;s;s;s)
              {s;(..)s?;qq qprint chr 0x$1 and \161 ssq;excess;}'


------------------------------

Date: 20 Apr 1998 23:32:48 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: Parser works sometimes
Message-Id: <6hglv0$a9r$2@client3.news.psi.net>

Gisle Aas (aas@sn.no) wrote on MDCXCIII September MCMXCIII in
<URL: news:m3bttw8ahu.fsf@furu.g.aas.no>:
++ abigail@fnx.com (Abigail) writes:
++ 
++ > ++     use HTML::Parse;
++ > 
++ > HTML::Parse won't do all of the above correctly :(
++ 
++ HTML::Parse (aka HTML::TreeBuilder) has trouble with lot of things.
++ The basic HTML::Parser only have problems with:
++ 
++    <![INCLUDE [CDATA [ >>>>>>>>>>>> ]]>
++ 
++ from Tom's examples.  It is parsed as:
++ 
++    DECL: [INCLUDE [CDATA [ 
++    TEXT: '>>>>>>>>>>> ]]>
++ 
++ should we fix that?


That would be real nice. Note that there's a [ too much in the example.
It's <![ INCLUDE CDATA [ >>>>>>>>>>>>>> ]]>.

But I wasn't aware that HTML::Parser knew about elements with CDATA
declared content. (HTML 4.0 as 2 of those elements).



Abigail
-- 
perl -wle '$, = " "; sub AUTOLOAD {($AUTOLOAD =~ /::(.*)/) [0];}
           print+Just (), another (), Perl (), Hacker ();'


------------------------------

Date: Sun, 19 Apr 1998 13:31:51 GMT
From: Bill 'Sneex' Jones <sneaker@earthling.net>
Subject: Re: Password changing under Solaris
Message-Id: <3539FB2D.67377DFB@earthling.net>

[Sorry for replying to my own post, but the formatter sux...]

Bill 'Sneex' Jones wrote:

> Findable under http://www.perl.com/CPAN/modules/by-authors/

> Lookup Austin Shutz :-)

Sorry for the mix up.
__________________________
Bill Jones...............|
Sneaker's Nest...........|
Chasecreek Systemhouse...|





------------------------------

Date: Sun, 19 Apr 1998 22:42:29 GMT
From: Bill 'Sneex' Jones <sneaker@earthling.net>
Subject: Re: Password changing under Solaris
Message-Id: <353A7C3A.1AB6660F@earthling.net>

This is a multi-part message in MIME format.
--------------2322933D57B6F85BA719F7F2
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Dave Haywood wrote:

>   To install I ran "perl ./Makefile.PL;make;make install".  All of this ran
> without error and installed.  However, I have now written a small program to
> perform the password change and get a multitude of errors!  If, after
> building, I run the "try" Perl program in the IO-Tty distribution, I get the
> following:
>
> Using /opt/src/gnu/perl-Expect/IO-Tty-0.02/blibCan't load
> '/opt/gnu/lib/perl5/sun4-solaris/5.00404/auto/IO/IO.so' for module IO:
> ld.so.1: /bin/perl: fatal: relocation error: symbol not found: main:
> referenced in /opt/gnu/lib/perl5/sun4-solaris/5.00404/auto/IO/IO.so at
> /opt/gnu/lib/perl5/sun4-solaris/5.00404/DynaLoader.pm line 166. at
> /opt/gnu/lib/perl5/sun4-solaris/5.00404/IO/Handle.pm line 248BEGIN
> failed--compilation aborted at
> /opt/src/gnu/perl-Expect/IO-Tty-0.02/blib/lib/IO/Tty.pm line 9.BEGIN
> failed--compilation aborted at
> /opt/src/gnu/perl-Expect/IO-Tty-0.02/blib/lib/IO/Pty.pm line 7.BEGIN
> failed--compilation aborted at ./try line 4.
>
>   Do you have any idea what the problem is?  I'd appreciate any pointers!
>
>   Thanks,

 No, sorry, I have RedHat 5.0 (Hurricane) with
Perl 5.004_64 at home and the IO::Tty 'try' script
ran without errors.  I have Perl 5.003 at work (on
an Ultra-1 and E3000) and haven't been able to
schedule an upgrade.  We use WCB and some
other Perl programs at work and I cannot afford
to break any of them right now.

What I would suggest is try reinstalling the
three modules above like this -

Inside each untarred subdirectory use:
perl Makefile.PL
make
make test
(and as root only) make install.

Note ANY errors or oddities
and report them in the c.l.p.modules
group, if they fail or weird out
on you...

Although the make test part above
may only work for IO:Tty (I don't
remember whether other two
actually had any tests defined...)

Also, you should concentrate your
efforts on the Expect portion, as that
will be the module which will actually
allow you change passwords, etc.

Also, FYI, I have attached the correct
output of 'try' below...

PS - I hope to have the Expect.pm
only version of WebPass.cgi available
soon.  Check at www.perl.com
for updates :-)
__________________________
Bill Jones...............|
Sneaker's Nest...........|
Chasecreek Systemhouse...|


--------------2322933D57B6F85BA719F7F2
Content-Type: text/plain; charset=us-ascii; name="output"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline; filename="output"

io_pty_ttyname/dev/ttya0
master IO::Pty=GLOB(0x80d1974) *Symbol::GEN0 /dev/ttya0
slave  IO::Tty=GLOB(0x80d17ac) *Symbol::GEN1 /dev/ttya0
1
2
3
4
5
6
7
8
9
10

--------------2322933D57B6F85BA719F7F2--



------------------------------

Date: Tue, 21 Apr 1998 00:05:26 GMT
From: jgloudon@hyssop.bbn.com.bbn.com (Jason Gloudon)
Subject: Re: Password changing under Solaris
Message-Id: <slrn6jnom2.75f.jgloudon@hyssop.bbn.com>

Brian Mathis <brianm@kodak.com> wrote:
 .
 .
>Hmm, well, I've found a much easier way to do this (to allow users to
>change their own login passwords from the web).  All you need to use is
>Net::Telnet.  You get all the information from the form, such as the
>username and password, then you telnet to "localhost" (or any host for
>that matter), and invoke passwd.  Then you can sort of Expect things
>without having to install all the extra modules that go along with
>Expect.pm.

This is on a machine running a web server ? I sincerely hope it isn't
publically accessible. You might think that's easy, but you are really landing
a man on Mars in order to orbit the moon. The error handling is terribly
messy; What do you do on a web server that has telnet disabled ? Or the user
aliases passwd to something else or sets a path like ~/bin:/usr/bin:/bin...

Just some reasons this is really a poor way to go about this.


Jason Gloudon


------------------------------

Date: Tue, 21 Apr 1998 00:09:16 GMT
From: Bill 'Sneex' Jones <sneaker@earthling.net>
Subject: Re: Password changing under Solaris
Message-Id: <353BE20F.A1E68EA5@earthling.net>

Brian Mathis wrote:

> Hmm, well, I've found a much easier way to do this (to allow users to
> change their own login passwords from the web).  All you need to use is
> Net::Telnet.  You get all the information from the form, such as the
> username and password, then you telnet to "localhost" (or any host for
> that matter), and invoke passwd.  Then you can sort of Expect things
> without having to install all the extra modules that go along with
> Expect.pm.
>
> Brian Mathis

 Without code, I assume you are not using Expect/TK?  Nor are you using Expect.pm?
That is a neat trick, to get the passwd piping to work and all :-)

Without code I would have to believe you :-)  I cannot do it without Expect/TK, and
then, if Expect/TK is installed, why telnet anywhere?  Oh well.
__________________________
Bill Jones...............|
Sneaker's Nest...........|
Chasecreek Systemhouse...|




------------------------------

Date: Tue, 21 Apr 1998 15:26:06 -0500
From: Holly Sommer <hsommer@micro.ti.com>
Subject: Re: Pattern Matching on HighBit Characters
Message-Id: <353D00DE.2AA37CDE@micro.ti.com>

Thanks for the suggestions and email :)

I found that:

s/[^\x2-\x7E]//g

did the trick most nicely. Now I can see that there is also real,
printable character junk intermingled with the octal stuff. This
is a more trivial s//.

Thanks, again :)

-Holly


------------------------------

Date: 21 Apr 1998 00:07:06 GMT
From: David Fetter <dfetter@shell4.ba.best.com>
Subject: Re: Perl 5.004_04 will not compile under Linux
Message-Id: <6hgnva$m5d$3@nntp1.ba.best.com>

William Burrow <aa126@NOSPAM.fan.nb.ca> wrote:

> After grabbing the huge Perl source to compile, doing a ./configure; make,
> I get the following error:

> util.c: In function `Perl_huge':
> util.c:2348: `__HUGE_VAL_bytes' undeclared (first use this function)
> util.c:2348: (Each undeclared identifier is reported only once
> util.c:2348: for each function it appears in.)
> make: *** [util.o] Error 1

> Is this a known problem?  What is the workaround?

Could you tell a little bit more about the Linux you've installed?
That can help to track things down a little bit.  Please include:

* libc version.  The command 'ls /lib/libc*' should tell you.
* gcc version (gcc -v)
* distribution (e.g. Red Hat, Slackware or SuSE)
* The kernel version (if it's earlier than 2.0.33, you need to upgrade)

HTH,
Dave.
-- 
            David Fetter         888 O'Farrell Street Apt E1205
   shackle@ren.glaci.com          San Francisco, CA 94109-7089 USA
  http://www.best.com/~dfetter     +1 415 567 2690 (voice)
print unpack ("u*",q+92G5S="!!;F]T:&5R(%!E<FP@2&%C:V5R"@``+)

The software required `Windows 95 or better', so I installed Linux.


------------------------------

Date: Wed, 22 Apr 1998 11:33:25 +1000
From: "Adrian Richardson" <adrianr@rmitpublishing.com.au>
Subject: Perl and IIS 4.0
Message-Id: <6hjh8o$jip$1@aggedor.rmit.edu.au>

Recently after upgrading from IIS3.0 to IIS4.0 our Perl scripts stopped
working.  They now give errors like.....

"The specified CGI application misbehaved by not returning a complete set of
HTTP headers. The headers it did return are:
Can't open perl script "???????????????????l??gf???????": Invalid argument"

This usually means that you don't have  'Content-type' etc in your script.
However, all of our scripts do and they run well under IIS3.0.

Does anyone know what we are missing here ?

Adrian






------------------------------

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
Message-Id: <null>


Administrivia:

The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc.  For subscription or unsubscription requests, send
the single line:

	subscribe perl-users
or:
	unsubscribe perl-users

to almanac@ruby.oce.orst.edu.  

To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.

To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.

To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.

The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.

The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.

For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.


------------------------------
End of Perl-Users Digest V8 Issue 2384
**************************************

home help back first fref pref prev next nref lref last post