[comp.lang.perl] possible problem with perl's TEST

tensmekl@infonode.ingr.com (Kermit Tensmeyer) (04/06/91)

I ran Configure, make depend, make TEST and
got these results

|	klt 154>perl TEST
|	base/cond......./base/cond.t: print: not found
|	./base/cond.t: =: not found
|	./base/cond.t: eq: not found
|	./base/cond.t: ne: not found
|	./base/cond.t: eq: not found
|	./base/cond.t: ne: not found
|	./base/cond.t: print: not found
|	./base/cond.t: ==: not found
|	./base/cond.t: !=: not found
|	./base/cond.t: ==: not found
|	./base/cond.t: print: not found
|	./base/cond.t: print: not found
|	FAILED on test 0
|	Failed a basic test--cannot continue.
|
|	klt 155>cd base
|	/mnt/klt/src/perl/perl.4/t/base
|
|	klt 158>../../perl *.t
|	1..4
|	ok 1
|	ok 2
|	ok 3
|	ok 4
|	
When I ran each of the test's individually everything come out hunky-dory.

Any Clues?


-- 
Kermit Tensmeyer                        | Intergraph Corporation
UUCP:     ...uunet!ingr!tensmekl	| One Madison Industrial Park
INTERNET: tensmekl@ingr.com		| Mail Stop LR23A2
AT&T:     (205)730-8127			| Huntsville, AL  35807-4201

guy@b11.ingr.com (Guy Streeter) (04/06/91)

tensmekl@infonode.ingr.com (Kermit Tensmeyer) writes:

>I ran Configure, make depend, make TEST and
>got these results

>|	klt 154>perl TEST
>|	base/cond......./base/cond.t: print: not found
>|	./base/cond.t: =: not found
...
>|	
>When I ran each of the test's individually everything come out hunky-dory.

>Any Clues?

Yes.  You ran it on a system whose interpretation of the #! magic
number is, let's say, "incomplete".  Those error messages come from
the shell, trying to interpret perl code.  I can't fault the configure
script, because the #! does work in some cases, but not all (popen()ed
scripts,  for example, won't work).

You need to go into config.sh and change it so it doesn't think #! works.

--
Guy Streeter
streeter@ingr.com

kgallagh@digi.lonestar.org (Kevin Gallagher) (04/06/91)

In article <1991Apr5.172457.10599@infonode.ingr.com> tensmekl@infonode.ingr.com (Kermit Tensmeyer) writes:
>I ran Configure, make depend, make TEST and
>got these results
>
>|	klt 154>perl TEST
>|	base/cond......./base/cond.t: print: not found
>|	./base/cond.t: =: not found
>|	./base/cond.t: eq: not found
>|	./base/cond.t: ne: not found
[...etc.]
>|	./base/cond.t: print: not found
>|	./base/cond.t: print: not found
>|	FAILED on test 0
>|	Failed a basic test--cannot continue.
[stuff deleted]
>When I ran each of the test's individually everything come out hunky-dory.
>
>Any Clues?

You did not identify the version of Unix you are running and the hardware you
are running on.  This would proved helpful.
-- 
----------------------------------------------------------------------------
Kevin Gallagher        kgallagh@digi.lonestar.org OR ...!uunet!digi!kgallagh
DSC Communications Corporation   Addr: MS 152, 1000 Coit Rd, Plano, TX 75075
----------------------------------------------------------------------------

mac@kpc.com (Mike McNamara) (04/15/91)

In article <guy.670894399@guy> guy@b11.ingr.com (Guy Streeter) writes:
>tensmekl@infonode.ingr.com (Kermit Tensmeyer) writes:
>
>>I ran Configure, make depend, make TEST and
>>got these results
>
>>|	klt 154>perl TEST
>>|	base/cond......./base/cond.t: print: not found
>>|	./base/cond.t: =: not found
>...
>>|	
>>When I ran each of the test's individually everything come out hunky-dory.
>
>>Any Clues?
>
>Yes.  You ran it on a system whose interpretation of the #! magic
>number is, let's say, "incomplete".  Those error messages come from
>the shell, trying to interpret perl code.  I can't fault the configure
>script, because the #! does work in some cases, but not all (popen()ed
>scripts,  for example, won't work).
>
>You need to go into config.sh and change it so it doesn't think #! works.
>
	Actually, perhaps not.  On my system, base/cond.t and friends start 
with 
#! ./perl
instead of
#! /bin/perl

	I do not know if that is how they were shipped, or if running
Configure changed them to that way.  I copied the perl distribution
from uunet, my machine is a Stardent 3000.
	In actuality, this could be a feature. Usually when you are
running TEST, you haven't yet installed perl; hence the test scripts should
look in a non standard place. The directory layout is as follows:

perl/
perl/perl
  ...
perl/t/
perl/t/TEST
  ...
perl/t/base/
perl/t/cmd/

	So how I naively ran the tests was to cd to t and type ./TEST.
If I had stayed in the perl directory, and typed t/TEST, then 
#! ./perl 
would have worked.  Or, a symbolic link could have been made from
t/perl to ../perl

	Just a layout problem...

>--
>Guy Streeter
>streeter@ingr.com


-- 
+-----------+-------------------------------------------------------------------+
|mac@kpc.com| Increasing Software complexity lets us sell Mainframes as         |
|           | personal computers. Carry on, X windows/Postscript/emacs/CASE!!   |
+-----------+-------------------------------------------------------------------+

lwall@jpl-devvax.jpl.nasa.gov (Larry Wall) (04/19/91)

In article <1991Apr14.235128.9435@kpc.com> mac@kpc.com (Mike McNamara) writes:
: 	So how I naively ran the tests was to cd to t and type ./TEST.
: If I had stayed in the perl directory, and typed t/TEST, then 
: #! ./perl 
: would have worked.

Only on t/TEST itself.  TEST immediately chdirs to t, so base/whatever.t looks
for perl in the t directory.

: Or, a symbolic link could have been made from
: t/perl to ../perl

Which is precisely what "make test" does.  The reason that the tests
look for perl in t/ is that it gives you the option of pointing the
symlink at some other perl to test, such as the currently installed one.

Larry