Subject: Re: Running Python Scripts
To: None <netbsd-users@NetBSD.org>
From: Jukka Salmi <j+nbsd@2004.salmi.ch>
List: netbsd-users
Date: 01/11/2005 17:37:54
Gary Parker --> netbsd-users (2005-01-11 16:23:31 -0000):
> Howdy all,
> 	today I compiled and installed python24-pth on my sparcstation 20
> running NetBSD 2.0
> 
> It all seems to run quite nicely and with no errors except that scripts
> starting with the traditional:
> 
> #!/usr/bin/env python
> 
> ...fail as the output of 'env python' doesn't actually give you the contents
> of the python environment variable (which I have manually set to
> /usr/pkg/bin/python2p4) but, rather, gives the following error message:
> 
> env: python: No such file or directory

Your PATH probably doesn't contain /usr/pkg/bin.


> It would appear that /usr/bin/env is trying to run the argument 'python' as
> an executable

That's what env(1) is supposed to do...


> rather than just printing out the variable's content.

Hmm, 'man env' should clarify this...


HTH, Jukka

-- 
bashian roulette:
$ ((RANDOM%6)) || rm -rf ~