All,
My apologies to anyone who actually tried to use the code I first sent
out (at the bottom). The old code in that snippet was commented out
with Ferret '!' characters instead of perl '#'. Needless to say, perl
didn't like them. I was negligent in not installing our new modules on
a clean machine to make sure the changed code was tested. The correct
code revision, which has been tested, is the following:
version 1.2, 2002/06/26 18:20:24 |
version 1.4, 2005/02/04 17:48:34 |
|
|
my $self = shift; |
my $self = shift; |
my $debug = 0; |
my $debug = 0; |
# From STREAM |
# From STREAM |
local *X = $_[0]; |
##
Test of file handle modified by Mike Godin to allow for easier |
print STDERR "arg: $_[0] ", fileno(X) , "\n" if $debug; |
##
installation on various RedHat-9 and ES systems. |
if (defined(fileno(X))) { |
## |
|
##
local *X = $_[0]; |
|
##
print STDERR "arg: $_[0] ", fileno(X) , "\n" if $debug; |
|
##
if (defined(fileno(X))) { |
|
my $fd = eval { fileno( $_[0] ) }; |
|
print STDERR "arg: $_[0] ", $fd, "\n" if $debug; |
|
if (defined( $fd )) { |
$self->[$STREAM] = $_[0]; |
$self->[$STREAM] = $_[0]; |
print STDERR
"From stream\n" if $debug; |
print STDERR
"From stream\n" if $debug; |
-- Jon
Jonathan Callahan wrote:
Adam,
As Andrew has already answered, test4 has a bug and is not required.
The ParseLex-2.15 source code distributed with our current 6.4.2
release of LAS should have test4 removed and another small bug fix in
ParseLex-2.15/lib/Parse/ALex.pm to help ParseLex compile on various
RedHat9 and ES systems. (Thanks to Mike Godin at MBARI.) Versions of
LAS prior to 6.4.1 will not have this fix in the source code.
Here is a snapshot of the code change to that file with the newer code
on the right..
version 1.2, 2002/06/26 18:20:24 |
version 1.3, 2004/07/26 21:46:08 |
|
|
my $self = shift; |
my $self = shift; |
my $debug = 0; |
my $debug = 0; |
# From STREAM |
# From STREAM |
local *X = $_[0]; |
!
local *X = $_[0]; |
print STDERR "arg: $_[0] ", fileno(X) , "\n" if $debug; |
!
print STDERR "arg: $_[0] ", fileno(X) , "\n" if $debug; |
if (defined(fileno(X))) { |
!
if (defined(fileno(X))) { |
|
my $fd = eval { fileno( $_[0] ) }; |
|
print STDERR "arg: $_[0] ", $fd, "\n" if $debug; |
|
if (defined( $fd )) { |
$self->[$STREAM] = $_[0]; |
$self->[$STREAM] = $_[0]; |
print STDERR
"From stream\n" if $debug; |
print STDERR
"From stream\n" if $debug; |
Let us know if you have any other problems getting your LAS
installation up.
-- Jon
Adam Baxter wrote:
Hi,
I'm working on the NOMADS project and we're trying to install LAS on
one of our servers. With the help of a few of the messages on this
mailing list, all of the prerequisites for LAS compile and test fine
except for ParseLex on test 4. We need to somehow move forward with our
installation, however and can't really wait for the next release of
LAS. Is something wrong with the test or is it ParseLex itself? Can the
test be safely ignored or is there possibly a patch to fix it?
Adam Baxter
Intern at NCDC/NEMAC
|