[8076] in Perl-Users-Digest
Perl-Users Digest, Issue: 1695 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Jan 21 16:17:49 1998
Date: Wed, 21 Jan 98 13:00:21 -0800
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, 21 Jan 1998 Volume: 8 Number: 1695
Today's topics:
Re: [Q] Database Reccomendations for Perl on Unix <keefner@kinetic.com>
Re: [Q]: my variables not showing up in perl debugger <merlyn@stonehenge.com>
auto refeshing with perl amd javascript <jahnel@xarch.tu-graz.ac.at>
Re: date & Expiration? <kupid@ecom.net>
Re: Embedded variable names in text files....possible? <*@qz.to>
Re: flat file db Vs Aliases.db by Perl. (Earl Hood)
FORTRAN format, help! <Y_Hu@fccc.edu>
Re: FORTRAN format, help! <Y_Hu@fccc.edu>
Re: GetOpts::Std and 'Use of Uninitialized variable' er <mhazen@franklin.uga.edu>
HTML perl scripts for Windows NT (jlk)
HTML to MAIL <kid@actioninternet.net>
Re: IIS4 Please Help! <cambrar@mail2.infoboard.net>
Re: living and free software (was: Re: source into bina (John Stanley)
Re: living and free software (was: Re: source into bina (John Stanley)
Re: PERL+ODBC vs Delphi for webwork <Jan@ChipNET.cz>
Re: Refering to a referenced structure? <dgoddard@us.oracle.com>
Re: Retreiving File from Remote Server <merlyn@stonehenge.com>
Re: source into binary code (John Stanley)
Re: source into binary code <jason@primal.ucdavis.edu>
Re: sysread vs <> and others (Mike Linksvayer)
timelocal.pl (I don't have it) <rlluhman@netins.net>
Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Wed, 21 Jan 1998 14:21:43 -0600
From: "Craig A. Keefner" <keefner@kinetic.com>
To: Brandon@byu.edu
Subject: Re: [Q] Database Reccomendations for Perl on Unix
Message-Id: <34C658D7.67410495@kinetic.com>
You might think about Sybase. They have a cheap unix version
of sqlanywhere (with path up to bigboys 10 and 11)
Craig
Brandon Pulsipher wrote:
> I have some Microsoft Access database's that I have been using thru Perl
> Win32:ODBC on a Windows NT webserver. The time has come to move to a
> Unix box. Obviously I there is not way for me continue using the
> MS-Access databases (at least that I know of). Therefore, does anyone
> have suggestions for what to convert these database to, so that I can
> work with them thru Perl 5 on Unix? I will be using a virtual host and
> do not have a huge amount of control to install other packages.
> If there may be a better solution to my problem, please let me know.
> Thank you.
>
> -Brandon Pulsipher
> -Brandon.Pulsipher@usa.net
------------------------------
Date: 21 Jan 1998 11:50:12 -0700
From: Randal Schwartz <merlyn@stonehenge.com>
To: swoneill@erols.com (Sean O'Neill)
Subject: Re: [Q]: my variables not showing up in perl debugger
Message-Id: <8cd8hlfyqj.fsf@gadget.cscaper.com>
>>>>> "Sean" == Sean O'Neill <swoneill@erols.com> writes:
Sean> Can anyone explain to me why using the following code segment:
Sean> sub subroutinename() {
Sean> my %rpt_obshash;
Sean> my %rpt_pathash;
Sean> my @rpt_patches;
Sean> blah blah blah
Sean> }
Sean> in the perl debugger do the variables beginning with rpt not
Sean> show up using the "X ~rpt" command? If I comment out the my'd
Sean> lines, it works fine. Isn't the debugger like the perl "god" of
Sean> its environment and see everything in its domain?
That's cuz "X" dumps package vars, not "my" (lexical) vars. You can
still look at the value by mentioning the name specifically, like "x
\@rpt_patches" while you are breakpoint-stopped within the routine.
print "Just another Perl hacker," # but not what the media calls "hacker!" :-)
## legal fund: $20,990.69 collected, $186,159.85 spent; just 222 more days
## before I go to *prison* for 90 days; email fund@stonehenge.com for details
--
Name: Randal L. Schwartz / Stonehenge Consulting Services (503)777-0095
Keywords: Perl training, UNIX[tm] consulting, video production, skiing, flying
Email: <merlyn@stonehenge.com> Snail: (Call) PGP-Key: (finger merlyn@teleport.com)
Web: <A HREF="http://www.stonehenge.com/merlyn/">My Home Page!</A>
Quote: "I'm telling you, if I could have five lines in my .sig, I would!" -- me
------------------------------
Date: Wed, 21 Jan 1998 21:28:50 +0100
From: Jahnel Klaus <jahnel@xarch.tu-graz.ac.at>
Subject: auto refeshing with perl amd javascript
Message-Id: <34C65A82.744C9C4@xarch.tu-graz.ac.at>
Hi all,
I have this in my perlscript to make an refresching output of something
<META HTTP-EQUIV=\"Refresh\" CONTENT=5 ;action =
\"http:/my.domaine.com/home/cgi-bin/now1.cgi \" method=post name
=\"Departure\" value=\"$ort\">
I ve a question about that:
How can i say it in this line to tell erl to read the value and the
name to refresh the page automatic?
what i am making wrong?
the first loading is ok but when it refreshes thhere are no datas in it.
Klaus
------------------------------
Date: Wed, 21 Jan 1998 12:38:07 -0800
From: "Kupid" <kupid@ecom.net>
Subject: Re: date & Expiration?
Message-Id: <6a5mai$lr$1@usenet40.supernews.com>
Thanks guys... Dang, I should have checked out some date functions in one of
my Perl books. Now, I have to write a search and replace program to
reformat "date" part in all my databases.
David
Matthew Cravit wrote in message <6a04f9$4rr$1@shell3.ba.best.com>...
>In article <6a02fk$b0o$1@usenet76.supernews.com>, Kupid <kupid@ecom.net>
wrote:
>>What I'm trying to do is make a certain line in a file delete 15 days from
>>the creation date. For example:
>>
>>On my website.. when a person posts a message, it goes into my
>>text-based...database. 15 days after the initial post.. I want the line
>>deleted from the database.
>>
>>Does anyone know of any date code, and the method in how to do this?
>
>The value of time() is an integer indicating seconds since January 1st,
>1970 (on UNIX, anyway). So you could timestamp your records with that
>value, and then in your code do something like this:
>
>use constant SECS_IN_15_DAYS => 1296000;
>
>[...]
>
>if (time >= ($timestamp + SECS_IN_15_DAYS)) {
> # Delete the entry
>}
>
>Hope this helps.
>
>/MC
>
>--
>Matthew Cravit, N9VWG | Experience is what allows you to
>E-mail: mcravit@best.com (home) | recognize a mistake the second
> mcravit@taos.com (work) | time you make it.
------------------------------
Date: 21 Jan 1998 20:34:38 GMT
From: Eli the Bearded <*@qz.to>
Subject: Re: Embedded variable names in text files....possible?
Message-Id: <qz$9801211452@qz.little-neck.ny.us>
Keywords: from just another new york perl hacker
Nicholas J. Leon <nicholas@binary9.net> wrote:
> In article <34C533E7.A473D2CD@seanet.com>, dawfun@seanet.com says...
> > I have a file called 'contact1.txt', and I want to open it and print the
> > contents to the screen. Within the text of this file I have what I
> > hoped would have been a variable name '$emailaddress', however upon
If you just have one variable to substitute, a very simple s/// will
work. I'd recommend
s/\$emailaddress\b/$emailaddress/g;
An example:
#!/usr/bin/perl -w
$line = 'The ny.pm list address is <$emailaddress>.';
$emailaddress = 'ny@lists.pm.org';
$line =~ s/\$emailaddress\b/$emailaddress/g;
print "$line\n";
__END__
:r! perl -x %
The ny.pm list address is <ny@lists.pm.org>.
> Try something like this,
> -- the text file, contact1.txt --
> Hello, my email address is %ADDRESS. Goodbye!
> -- the perl script that outputs it --
> #!/usr/bin/perl
You should have a -w there.
> my $email="dawfun\@seanet.com";
If you don't want interpolation, don't use double quotes.
> open IN,"<contact1.txt" || die $!;
This is not going to work the way you want it to: "||" has a higher
precedence than ",".
> while (<IN>) {
> s/%ADDRESS/$email/g;
> print;
> }
> close IN;
>
> -- end --
>
> I use %XXXX notation for substitutions instead of $xxxx so that they can
> easily be written into regex's.
You don't gain anything really here, particularly not if you want something
like this:
#!/usr/bin/perl -w
my $line;
my $emailaddress;
$line = 'The ny.pm list address is <$emailaddress>. We meet at $meeting.';
$emailaddress = 'ny@lists.pm.org';
my $foo;
$line =~ s/(\$\w+)\b/ $foo=eval '$1', defined(eval "$foo")?"$foo":'$foo' /eeg;
print "$line\n";
__END__
:r! perl -x %
The ny.pm list address is <ny@lists.pm.org>. We meet at $meeting.
Elijah
------
"my" does not seem to work well in a /e context...
------------------------------
Date: 21 Jan 1998 20:26:27 GMT
From: ehood@medusa.acs.uci.edu (Earl Hood)
Subject: Re: flat file db Vs Aliases.db by Perl.
Message-Id: <6a5llj$rij@news.service.uci.edu>
In article <885324596.516554765@dejanews.com>, <ming@utesa.edu> wrote:
>How can I 'insert' in my Sendmail 8.x a flat file db? I have all forward
>information in a flat file Db instead of 'aliases' file, how can I make
>my sendmail run a perl script everytime when a new message come in? (that
>perl script will search over flat file DB and return a forward address to
>sendmail,if any) I really have no idea to do it...
Let me rephrase your problem sin the hopes of understanding the
problem
You have a custom alias db that you want sendmail to use when
performing alias lookups on local addresses.
The initial (and simplest) approach I would take is convert your db
into a sendmail aliases text file (eg /etc/mail/aliases), and let
sendmail do the rest. If for maintenance purposes, you want to
maintain the list in your db format, you can make changes in your db
and run the conversion utility to translate to /etc/mail/aliases. You can
use cron to automate the task. Some care should be taken so you
do not clobber the important aliases (like postmaster), unless you
define them in your db.
Sendmail automatically rebuilds its database from the /etc/mail/aliases
file if it changes into a dbm, or similiar format, database faster
lookups. You can try dealing with the dbm file directly, but I would
discourage it since the aliases text file would go out of sync, and if
it gets touched in anyway, any back door changes to the dbm database
would get lost.
If you are ambitious, you can modify sendmail itself to use a different
technique to do alias lookups. I believe the sendmail source is
designed to allow alternate database formats to be hooked into
sendmail.
This topic is probably more suitable for the comp.mail.sendmail
group.
--ewh
--
Earl Hood | University of California: Irvine
ehood@medusa.acs.uci.edu | Electronic Loiterer
http://www.oac.uci.edu/indiv/ehood/ | Dabbler of SGML/WWW/Perl/MIME
------------------------------
Date: Wed, 21 Jan 1998 13:41:50 -0500
From: Ying Hu <Y_Hu@fccc.edu>
Subject: FORTRAN format, help!
Message-Id: <34C6416E.41C6@fccc.edu>
Perlers:
How to get FORTRAN format by perl for example:
data:
string1 12345.67 89 ing2
stri 12345.6 9 string2
ring1 45.67 89 string2
FORTRAN format:
(A7,2X,F8.2,4X,I2,A7)
Thanks
Ying
------------------------------
Date: Wed, 21 Jan 1998 15:08:03 -0500
From: Ying Hu <Y_Hu@fccc.edu>
Subject: Re: FORTRAN format, help!
Message-Id: <34C655A3.167E@fccc.edu>
Perlers:
>
> How to get FORTRAN format by perl for example:
>
> data:
> string1 12345.67 89 ing2
> stri 12345.6 9 string2
> ring1 45.67 89 string2
>
> FORTRAN format:
> (A7,2X,F8.2,4X,I2,A7)
My question is how to get "(A7,2X,F8.2,4X,I2,A7)" from the
data by perl. Sorry!
Ying
------------------------------
Date: Wed, 21 Jan 1998 14:23:08 -0500
From: Mark Hazen <mhazen@franklin.uga.edu>
To: Tom Phoenix <rootbeer@teleport.com>
Subject: Re: GetOpts::Std and 'Use of Uninitialized variable' errors?
Message-Id: <Pine.WNT.3.95.980121142132.-116015D-100000@fcsg1.franklin.uga.edu>
On Tue, 20 Jan 1998, Tom Phoenix wrote:
> On Tue, 20 Jan 1998, Mark Hazen wrote:
>
> > Ah, but I get errors if I try to do a File::Find in a directory that
> > isn't in ENV{'PATH'} if I've got taint checks on.... :(
>
> I think you're mistaken; in my experience, you needn't have any entry in
> your PATH except for a directory which contains a program you'll be
Ah, you are correct. I was mistaken; adding pwd's directory into my path
did indeed fix the problem. :)
> For good security, you can't be too paranoid. :-)
Many many thanks... Perl is definitely one of these languages in which
I've learned more by doing things the *wrong* way and figuring out just
where I goofed... :)
-mh.
----
. _+m"m+_"+_ Mark Hazen Network Administrator, Dean's Office
d' Jp qh qh The Franklin College of Arts & Sciences
Jp O O O The University of Georgia (706)542-1546
Yb Yb dY dY
O "Y5m2Y" " even the mightiest wave starts out as a ripple.
"Y_ why make waves when it's easier to nurture ripples?
------------------------------
Date: Wed, 21 Jan 1998 19:33:15 GMT
From: lien@cs.umb.edu (jlk)
Subject: HTML perl scripts for Windows NT
Message-Id: <%3sx.10$Ps3.324411@cam-news-reader1.bbnplanet.com>
How to do perl in HTML page on Windows NT platform.
I know in Unix I can do HTML as below:
#!/usr/local/bin/perl
use CGI qw(:standard);
print header;
print start_html('My Simple Example'),
h1('My Simple Example'),
start_form,
......
How about Windows NT?
I don't think I can use #!/usr/local/bin/perl as perl path.
Thank you....
------------------------------
Date: 21 Jan 98 20:37:46 GMT
From: "S Newberg" <kid@actioninternet.net>
Subject: HTML to MAIL
Message-Id: <01bd26ac$6e0602c0$825f04d1@dos>
I am having some trouble with a lil perl script that sends contents from an
HTML input, but I can't seem to get it to mail those contents. I can get it
to mail, but the origonall contents I read in never show.
I am a novice perl programmer and appreciate any suggestions. The output at
the bottom is definately what I am doing wrong. I found the script and
fixed many bugs, but can't get the origonall %input to be outputed to the
message body of the Email message.
####Snipped------------------
# get the input from the form into the associative array %input.
&ReadParse(*input);
&domail; #try to send the mail
if ($status) #send the client an html page with
{
&respond_ok;
}
else
{
&respond_notok;
}
##snipped to output section --------------------
sub sendmail
# talk SMTP to the mail hub. Fail if anything goes wrong.
#
# $mailfrom = email address this is from: i.e. root@domain.com
# $mailfromname = real name of sender: i.e. Root User
# $mailto = email address this is to: i.e. root2@otherdomain.com
# $subject = Message Subject
#
{
#&tracein('sendmail');
if (&get_reply()){
send (S,"HELO localhost\n",0);
if (&get_reply()){
send (S,"MAIL FROM: <$mailfrom>\n",0);
if (&get_reply()){
send (S,"RCPT TO: <$mailto>\n",0);
if (&get_reply()){
send (S,"RCPT TO: <$postmaster>\n",0);
if (&get_reply()){
send (S,"DATA\n",0);
send (S,"From: <$mailfrom> ($mailfromname)\n",0);
send (S,"Errors-To: $postmaster\n",0);
send (S,"Reply-To: $mailfrom\n",0);
send (S,"Subject: $subject\n",0);
send (S,"\n",0);
send (S,"message body\n",0);
send (S,%input,0); ## THIS IS WHERE I CAN"T GET THE OUTPUT
send (S,"\r\n.\r\n",0);
}
if (&get_reply()){
send(S,"QUIT\n",0);
if (&get_reply())
{
$status = 1;
}
}
}
}
}
}
return($status);
}
------------------------------
Date: Wed, 21 Jan 1998 15:05:03 -0500
From: Rob Cambra <cambrar@mail2.infoboard.net>
To: tmoore@starsysfw.com, webmaster@pacificanet.com
Subject: Re: IIS4 Please Help!
Message-Id: <Pine.GSO.3.95.980121145844.16340A-100000@infobsun2.infoboard.net>
I am having the same problem with this isapi filter.
I thought maybe activestate's setup scripts were broke, so I did it
manually and confirmed everything was set up correctly, (and identical to
my IIS3 servers) but it continues to fail to load perl, the exact message
from event viewer is:
The HTTP server was unable to load the ISAPI Application
'C:\Perl\bin\PerlIS.dll'. The data is the error.
Which is a generic "i can't run that" message. I am thinking it has to do
with isapi changing the interface a bit between 3 and 4, as this is not
the first isapi application I have had problems with on 4 that worked on
3.
I guess I will contact activestate directly on this issue, but I was just
wondering if maybe I am doing something wrong and if anyone has gotten
perl5 isapi and iis4 to work.
Associating it with perl.exe should always work, as it uses regular io
redirection in this case and not isapi methods, which I know have been
modified since 3.0.
-rob
On Mon, 19 Jan 1998 tmoore@starsysfw.com wrote:
> On Sat, 3 Jan 1998 00:46:55 -0600, "Bob Martin" <BobMartin@inu.net>
> wrote:
>
> >I just got IIS4.0 to run my scripts. First, I recommend that you map .pl to
> >PerlIs.dll. That way you don't run multiple instances of Perl.exe, and you
> >don't leave yourself open to hackers.
> >
>
> I tried this Bob... I got a message that it couldn't find the
> specified module. Mapping to perl.exe works well however. I am
> using Active State's Perl. If you have any insights on what the
> problems might be, I would prefer to be running the .dll.
>
> Thanks
> Tom Moore
> tmoore@starsysfw.com
>
>
>
>
------------------------------
Date: 21 Jan 1998 19:50:57 GMT
From: stanley@skyking.OCE.ORST.EDU (John Stanley)
Subject: Re: living and free software (was: Re: source into binary code)
Message-Id: <6a5jj1$g6q$1@news.orst.edu>
In article <54ra61hg9z.fsf@gunnar.aladdin.net>,
Piers Cawley <pdcawley@bofh.org.uk> wrote:
>No he doesn't. Take a look at WebEvent, a rather neat set of perl
>scripts to do web based calendars and the like. Comes with
>(unobfuscated) source and requires a keystring to get it working. The
>license requires the purchaser/evaluator not to either remove or
>subvert the licence handling code.
So the purchaser removes the keystring code, because he has the source
and can do so, and takes the code home to use there without paying for
it.
So an employee of the purchaser copies the code, and when he goes to work
somewhere else, he removes the keystring code ...
So the copy that shows up at the next site no longer has a copyright
notice or keystring code, and someone there, acting in good faith,
copies the code a dozen other places. Those dozen go another dozen.
>We're buying the software. Sure I
>could dike out the licensing stuff but what would be the point -- we
You could run multiple copies of the code for free. Saves you money.
You could run it at home, if you wanted, or if you change jobs and
didn't want to lose the functionality, you could take a copy with you.
That would be the point.
>get value from the code (what's especially neat is the fact that we
>can tailor it to our own requirements) so we pay for it. I'm an honest
>guy.
Yep. Not everyone is. If everyone were honest, we wouldn't need
passwords on computers, now would we?
>If the author had compiled it in some way then we could still dike out
>the licensing code; it would be harder to do, but it could be done.
Yes, yes, yes, of course it could be done. Nobody has said it couldn't.
It would be much harder to do, and then you have to start considering
the costs of doing that versus the cost of buying another license. As
long as it costs more to edit the object code than it does for a
license, you save money by getting a license.
>But in compiling the code one of the advantages of the software goes
>away; we can't see inside it.
To you this is an advantage. To the author, it isn't.
>Of course some unsrupulous lusers are going to circumvent the
>protection and keep using the software anyway, but they'd be doing
>that no matter how I distributed said software.
That statement is simply wrong. Those who do not have the ability or
time to figure out what part of the object code to edit will not be
able to use the software for free if you don't distribute source. That
applies to most people. In other words, it does matter how you
distribute it.
>> The question was asked "why would people pay for code they could get
>> for free?" When that was asked, there were two different programs
>> written by two different people. In this case, the code was written by
>> the same person. Why would anyone hire this guy to write code they
>> already had?
>
>Off the top of my head?
Yep, there are reasons, but not as many as when you don't have the
source and thus can't tinker with the code yourself.
>2. Because the GPL explicity disclaims any warranty; the license
> granted someone who pays for the software may not.
Hmmmm, read the GPL.
>Also, from the programmer's point of view, the free version of the
>software is an advert. Look at Larry for example, I don't know how
>much O'Reilly are paying him, but I'm fairly sure that they wouldn't
>have employed him if he hadn't written perl.
Ummmm, stop and think for a minute. I bet O'Reilly employs a lot of
people who haven't written perl. I bet the majority of people at
O'Reilly haven't written perl, or any other language.
>Actually, some of them did give it away. Code that comes from UCB for
>example was not paid for by the US government.
Should we review the funding status of UC or just admit that federal
money went in the door?
>> Now look at someone who is trying to sell his code. He LOSES a sale
>> if he gives it away. That means he loses money. He isn't being paid
>> to give it away. He is NOT making a living by giving code away. Do
>> you get the point yet?
>
>Which particular sale does he lose when he gives the code away? Randal
>and Tom give code away all the time, and they make a decent living
>(even if it doesn't cover the legal bills...).
Not by giving code away. They make a living giving classes, writing
books and articles, and other things that they get paid to do.
------------------------------
Date: 21 Jan 1998 20:30:29 GMT
From: stanley@skyking.OCE.ORST.EDU (John Stanley)
Subject: Re: living and free software (was: Re: source into binary code)
Message-Id: <6a5lt5$bf4$1@news.orst.edu>
In article <6a5ek4$i37$2@info.uah.edu>, Greg Bacon <gbacon@adtran.com> wrote:
>In article <6a2os0$fm5$1@news.orst.edu>,
> stanley@skyking.OCE.ORST.EDU (John Stanley) writes:
>: In article <6a2g9c$koh$1@info.uah.edu>, Greg Bacon <gbacon@adtran.com> wrote:
>: >What need does software I can't use meet?
>:
>: Why do YOU refuse to argue sensibly? The context of this discussion is
>: paying for code, which would give you the ability to use the code. Thus,
>: the only reason you claim you can't use the code is because you decided
>: not to pay for it. You called it useless just because YOU made the
>: choice that you wouldn't use it.
>
>Ah.. I see your confusion. To paraphrase Our Former Pumpking:
>``Software without sourcecode isn't software; it's hardware on disk''.
I don't care how you want to change the definition of hardware. Most
people call it software. In any case, you CAN use whatever it is you
call it, if you pay the license fee. You have decided not to use it, but
that does not make it useless for others. I see you neatly avoided the
issue.
If your whole problem is that you don't want to call it software, then
fine, it isn't software, and the argument is over. How important is it
to you to call it hardware?
>and share what I've done with the world. The latter seems like a much
>better situation for everyone.
Everyone except the person who wrote the code and is trying to feed his
family by selling updates and upgrades to the code. Everyone except the
person who came up with a neat new algorithm and is being denied the
fruits of his labors.
>You're under the impression that people are saying that it's possible to
>make a living by giving things away. I think we can both agree that no
>reasonable person would believe this.
Yes, I can agree with that.
>I believe that Tom {C,P} are reasonable people.
That is a good place to start.
>Therefore they don't believe that it's possible to
>make a living solely by giving things away.
I can't vouch for what they do or do not believe. I do not believe that
you have any special conduit that provides this information to you,
either. All we both have is 1) what they say, and 2) how they act. From
that, we must infer what they believe.
>Why would they make a claim against their own beliefs?
I doubt that they would. However, people sometimes do.
>: Except people HAVE been claiming the opposite. You really ought to read
>: what has been written. You included such a claim.
>
>*sigh*
I see that you noticed the quote and are exasperated that you finally
did. I can get no other meaning from your sigh except that.
>: Is this the same Richard Stallman who was given money to produce
>: software for free?
>
>No, people donate money to him because they find his free software very
>useful.
Money to produce more free software.
>: Now, if you want to help people, tell them where they
>: can get Gnu-unix.
>
>But GNU's Not Unix! :-)
If you expect me to read about Richard Stallman, perhaps you should
read about him also. His goal, as I remember what I have read about
him, was to produce a version of UNIX, in source, that could be
distributed freely. Not what AT&T call UNIX, but a version of with the
same functionality etc.
What I am pointing out to you is that he did not produce that. GNU came
out with a lot of the utilities, and improved a lot of utilities, but
did not produce the thing that was their goal.
>: >You're really reaching now, Stanley. First, using your intentionally
>: >obfuscated end product, they can only benefit from what you've learned
^^^^^^^^^^^^^^^^^^^^^
>: >in that they're bound by the bugs present and the features that aren't
>: >present; they can't fix or improve upon your work.
>:
>: Now you are reaching. Suppose this end product is the code to run an
>: MRI. Are you REALLY SERIOUSLY claiming that the only benefit people get
>: from the use of my code is that they are stuck with bugs and can't
>: modify the code? Are you REALLY saying that there is NO benefit to them
>: from the ability to see damage to soft tissue? There is NO benefit to
>: anyone when a doctor can see where a tumor is in advance of cutting open
>: someone's head?
>
>Try reading before refuting next time. I didn't deny that obfuscated
>software can provide benefit.
"They can only benefit ... in that they're bound by the bugs..." If you
really don't mean what you write, why don't you just say you wrote
something you didn't mean?
>However, that benefit is limited by the owner's knowledge and ability
>to program.
I think that a program that can be used to help heal millions of people
is pretty unlimited in its benefit.
>: Or maybe you just don't realize that there is software running the MRI.
>: And CAT scanner. And most laboratory equipment these days. Do you expect
>: source for all of those or they are useless?
>
>Hukt on fonnex fayld 4 u, d00d.
I guess you can't answer a simple question.
>: I guess when you can't argue the point, ignore it. No, you already said
>: that there is no benefit to anyone from MRI software that doesn't have
>: source provided with it.
>
>First your straw man arguments, and now you're putting words in my mouth.
You told me the only benefits. If they are the only benefits, and they
aren't benefits at all, then there must be no benefit.
>: Ok, so they aren't taken out an shot. They are certainly harmful to
>: society (your claim), so what DO you want done to them?
>
>I'd like to see society educated so they will know there are infinitely
>better and infinitely cheaper choices.
So you are now saying that there are no costs associated with free
software? That is the only way the choices could be infinitely cheaper.
>: So he decides to sell the software he writes.
>: Any problem there?
>
>What you call ``selling software'' I (and many others) would call
>``selling hardware on disk''. Why can't he sell his services as a
>programmer instead?
Because he doesn't want to have to play 1000 games making 1000 different
versions of his code for 1000 people who will expect him to give
lifetime support. He wants to sell what he has written.
As for your new definition of "hardware", big deal. Most people would
call it software, just as the courts call it software, and every shrink
wrap license calls it software.
>: He learns from his first experience at selling Perl
>: software that once he makes the SOURCE available he can no longer charge
>: for the ability to use the software
>
>Horrors! :-)
Yep. When the checks don't come in, and when he calls on prospects and
they say "I don't need your software, we got a copy of something off the
net for free", he's stuck trying to pay bills.
>: So he decides to distribute his
>: work in a form that requires a license to use it.
>
>Evil..
Baloney. A way to protect his investment in time and money.
>was it you who first pitched this idea to Unix vendors? 'Just
Get a clue, Greg.
>: Do you have a problem
>: with people requiring a license to use code?
>
>Yes, I have a big problem with it.
Too bad. It happens all the time. It's a part of the intellectual
property laws. In fact, it's in the US Constitution -- under the section
that created the Patent Office. Creators have a right to control their
intellectual property.
>Licenses are the equivalent of
>squeezing every last drop of water out of a rag when a couple of turns
>would do.
So you think that someone can live adequately by selling two copies of a
piece of software that sells for $1000 instead of many copies of the
software?
>: But to distribute it this
>: way, for Perl, he needs to hide the source.
>
>Perhaps he should choose a language better suited to his greed.
I would find it interesting if your employer started referring to your
desire to take a paycheck home as "greed" and started thinking your
altruism was missing because you wanted money.
>: Oops, seems to be a problem.
>: He must release his code for free or he is harming society.
>
>How ironic that you hold such contempt for the truth. I don't guess
>you've read ``Why Software Should Be Free''.
I hold contempt for false claims. When you speak the truth, I'll happily
agree with you.
>: Of course they do. But they aren't writing cheap software, they are
>: writing software that is complicated enough and specialized enough that
>: people will pay a living wage to them while they do it.
>
>So what is your problem with this arrangement?
I'll say it again, for the thousandth time, I HAVE ABSOLUTELY NO PROBLEM
WITH THIS ARRANGEMENT AT ALL. Perhaps you didn't read any of the
previous times that I have said this.
>: Excuse me, but let's travel down memory lane. Yesterday I read an
>: article from someone who was arguing for free software based on his
>: experiences with programmers who joined cults.
>
>More strawmen? It's getting really hot in here...
Well, Greg, I didn't write the article that told us of the travails of
the client with missing programmers. If you have a complaint about straw
men, go talk to him.
>: Did you forget
>: that he was paid to write it?
>
>We're all free to fix our cars or our plumbing, but we choose to call
>a mechanic or a plumber for the benefit of their experience. Why does
>everyone think programming is something everyone should do for
>themselves?
Maybe because the excuse that is being given so often for why "free
software" is so good is that it allows people to examine AND MODIFY
software when they want to.
>You're building another straw man now. There is an infinite amount of
>programming work to be done. Real programmers don't have to stop at
>one program.
And programmers who have invested a large amount of time and effort
into coming up with good software to do a large job should not be
limited to selling that software once and then giving it away. It is
not unlikely that a programmer who has written a program may sell it
for less than his cost to write it. In fact, there are shelves of
software at the local software store that sell for less than the cost
to write the code. I am certain that it took many hours for the person
to write the flashy calendar maker program I bought for $13. But that
programmer is amortizing his costs over many copies sold.
>: The question was asked "why would people pay for code they could get
>: for free?" When that was asked, there were two different programs
>: written by two different people. In this case, the code was written by
>: the same person. Why would anyone hire this guy to write code they
>: already had?
>
>They're not paying for the program. They're paying for the services
>of a programmer who can do work that they're unable to do for
>themselves.
Please go back and read the thread. The question was, why would people
pay for CODE that they can get a version of for free.
>It is this sort of shortsightedness that prevents free software from
>really taking over.
Yes, mine and all of those people who continue to sell software. My, if
this idea didn't work, you would think they would give up doing that
way.
>: I have been around long enough that I am not taken in by the hyperbole
>: about the "Information Superhighway" and all the warm fuzzies of people
>: wandering the great museums of Italy via cyberspace. I'm sorry that the
>: AOL/IBM advertising hype has taken you in.
>
>More shortsightedness..
Yes, yes, I am sure it is.
>: The telephone system is not a
>: Utopia, and it has been around a lot longer.
>
>Longevity does not necessarily produce Utopia. I've never made that
>claim.
It has many of the same properties of the Internet. If the Internet
were a Utopia, then the telephone system would be one. The fact that
people cannot live on the Internet means that any comparison to Utopia,
for real people, is ludicrous.
------------------------------
Date: Wed, 21 Jan 1998 19:49:41 -0800
From: Jan Krynicky <Jan@ChipNET.cz>
Subject: Re: PERL+ODBC vs Delphi for webwork
Message-Id: <34C6C1D5.156D@ChipNET.cz>
Jeffery Chow wrote:
>
> Hi. I apologize for the crosspost, but I'm desperate for comments and
> was hoping to get as many views as possible.
> I'm faced with a difficult decision that I must make for
> my boss in one of my university's co-op offices. We have a paradox7
> database that we'd like to publish on the www and allow students to
> make changes to their status/information/etc.
>
> I've implemented a stopgap solution using PERL32 and the ODBC
> library, but the ODBC driver we're using (by MS, came bundled
> with Office97 Dataacc package) is failing with an obscure error
> that MS won't solve for me.
>
> PERL+ODBC:
> (+) I'm already familiar with it, and have already written a moderate
> amount of PERL code
> (+) continuing with PERL+ODBC is cheapest solution, ODBC driver costs
> $800
I never actualy worked with Paradox databases, are you realy sure
the problem cannot be solved? Try to tell the group what's wrong.
(Maybe ask at Perl-Win32-Database@ActiveState.com mail conference.)
> (-) PERL scripts have notable overheads when loading interpreter
Not necessarily true. If you use the ActiveState port you may
interpret your scripts by an ISAPI dll, which is loaded all the time.
No processes need to be created, no EXEs to be loaded.
Speeds up things a lot.
See http://www.activestate.com/
>
> Please comment on these topics, any views would be greatly appreciated.
>
> more of a unix person,
> Jeff
Jenda
------------------------------
Date: Wed, 21 Jan 1998 11:18:44 -0800
From: Denis Goddard <dgoddard@us.oracle.com>
Subject: Re: Refering to a referenced structure?
Message-Id: <34C64A14.B463741C@us.oracle.com>
Andrew Johnson wrote:
> Wade Williams wrote:
> >
> > This one is driving me crazy.
> >
> > I've learned how to use references, but how do I get the structure pointed
> > to by the reference?...<questions snipped>
> here's a couple examples:
> ...<examples snipped>
I cannot recommend highly enough
_Advanced Perl Programming_, by S. Srinivasan
(no, I get no royalties or kickbacks!)
The descriptions and examples of references have helped me very much
and they can help you, too.
-Denis
------------------------------
Date: 21 Jan 1998 11:55:13 -0700
From: Randal Schwartz <merlyn@stonehenge.com>
To: John Kotwicki <Webmaster@csa.clpgh.org>
Subject: Re: Retreiving File from Remote Server
Message-Id: <8c4t2xfyi6.fsf@gadget.cscaper.com>
>>>>> "John" == John Kotwicki <Webmaster@csa.clpgh.org> writes:
John> Problem: I set up a standard socket connection with a Web
John> server. I know it works because I have tested it with random
John> Web sites. However, some Web sites do not return what I ask
John> for. They simply did nothing and returned no errors.
John> The code I use after the connection is made is:
John> print S "GET $url HTTP/1.0\n\n";
John> while ($_ = <S>) {
John> print $_;
John> }
Problem: You're simply working too hard:
use LWP::Simple;
getprint($url);
LWP is in the CPAN. Dozens of examples of using LWP can be found at
http://www.stonehenge.com/merlyn/WebTechniques/.
print "Just another Perl hacker," # but not what the media calls "hacker!" :-)
## legal fund: $20,990.69 collected, $186,159.85 spent; just 222 more days
## before I go to *prison* for 90 days; email fund@stonehenge.com for details
--
Name: Randal L. Schwartz / Stonehenge Consulting Services (503)777-0095
Keywords: Perl training, UNIX[tm] consulting, video production, skiing, flying
Email: <merlyn@stonehenge.com> Snail: (Call) PGP-Key: (finger merlyn@teleport.com)
Web: <A HREF="http://www.stonehenge.com/merlyn/">My Home Page!</A>
Quote: "I'm telling you, if I could have five lines in my .sig, I would!" -- me
------------------------------
Date: 21 Jan 1998 19:33:17 GMT
From: stanley@skyking.OCE.ORST.EDU (John Stanley)
Subject: Re: source into binary code
Message-Id: <6a5iht$5m1$1@news.orst.edu>
In article <Pine.OSF.3.95.980120170623.31207c-100000@primal.ucdavis.edu>,
Jason Christian <jason@primal.ucdavis.edu> wrote:
>> You will either pay the licensing fee or not. You don't get to set the
>> price for my code. I do.
>
>No you don't.
When you tell me that I do not get to set the price I charge for my
services, there is nothing left to discuss.
------------------------------
Date: Wed, 21 Jan 1998 12:28:38 -0800
From: Jason Christian <jason@primal.ucdavis.edu>
Subject: Re: source into binary code
Message-Id: <Pine.OSF.3.95.980121122328.31207h-100000@primal.ucdavis.edu>
On 21 Jan 1998, John Stanley wrote:
> In article <Pine.OSF.3.95.980120170623.31207c-100000@primal.ucdavis.edu>,
> Jason Christian <jason@primal.ucdavis.edu> wrote:
> >> You will either pay the licensing fee or not. You don't get to set the
> >> price for my code. I do.
> >
> >No you don't.
> When you tell me that I do not get to set the price I charge for my
> services, there is nothing left to discuss.
I agree with the conclusion. But when you quote part of a line, and
throw away the rest, then you come awfully close to lying. The
original lines read:
<QUOTE>
No you don't. No I don't. There are various levels and amounts of
software services that I am willing to buy at various prices. You
have a similar relationship for your supply of software (services).
Your unwillingness to release source code, while your right,
influences
my willingness to buy. I will pay a lot more for the same
functionality if I have access to the code. *I* am willing to accept
a covenant against reuse of code by others other than myself or my
agents...but I do need to be able to show the code to programmers who
come for me later.
</QUOTE>
You have no more ability to coerce me into buying at a price that I
consider unreasonable than I have to coerce you into selling at an
unreasonable price.
Your surgery on my line is dishonest. In any case, so far as I am
concerned this thread is finished on c.l.p.m.
---------------------------------------------------------------------------
Jason Christian University of California, Davis
jason@primal.ucdavis.edu Agricultural and Resource Economics
Office:(530)752-1357 FAX:(530)752-5614 Davis, CA 95616
------------------------------
Date: 21 Jan 1998 12:23:04 -0800
From: ml@gondwanaland.com (Mike Linksvayer)
Subject: Re: sysread vs <> and others
Message-Id: <6a5lf8$edf$1@shell3.ba.best.com>
In article <6a5ald$m03$1@lyra.csx.cam.ac.uk>, M.J.T. Guy <mjtg@cus.cam.ac.uk> wrote:
>Justin Vallon <vallon@pearl.fi.bear.com> wrote:
>> my $buf;
>> open(F,"foo") || die $!;
>> $buf = join "", <F>;
>> close(F);
This is even slower than the while { $buf .= $_; } version. I'd
guess that the join is expensive?
> my $buf;
> open(F,"foo") || die $!;
> { local $/; $buf = <F> };
> close(F);
>
>I'd expect that to be almost indistinguishable from sysread.
It's about twice as slow as sysread, but a huge improvement over
reading line by line.
Here are times for all four versions posted (plus one using read
instead of sysread) in seconds:
0.0027 stat file, read whole thing with sysread
0.0039 stat file, read whole thing with read
0.0058 local $/, read whole file with <F>
0.0318 while (<F>) { $buf .= $_; }
0.0367 $buf = join "", <F>;
This is using Perl 5.004_4, Solaris 2.6 on an ultra1. Times
generated as so:
use Time::HiRes qw(gettimeofday tv_interval);
use strict;
my $t0 = [gettimeofday];
# code to time here
print sprintf("%f",tv_interval($t0));
I guess I could run each version a million times using Benchmark,
but I'm slothful.
Now I have just one more question: Is there any reason to use read
instead of sysread unless you are doing multiple reads on the file?
They both return undef on failure, so I wouldn't think that there
is a safety reason.
--
Mike Linksvayer http://gondwanaland.com/ml/
------------------------------
Date: Wed, 21 Jan 1998 13:32:18 -0600
From: "Rick" <rlluhman@netins.net>
Subject: timelocal.pl (I don't have it)
Message-Id: <6a5ia7$fme$1@news.iastate.edu>
I have located a script the requires timelocal.pl. However, our version of
Perl (5.0 on IntraNetware) does not have timelocal.pl. Can this script be
obtained? Will it work on IntraNetware?
RICK
------------------------------
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 1695
**************************************