Off-topic

Ivan Van Laningham ivanlan at callware.com
Wed Apr 12 14:49:16 EDT 2000


Hi All--

Michael Hudson wrote:
> 
> Ivan Van Laningham <ivanlan at callware.com> writes:
> 
> > Hi All--
> > This is not precisely about Python, but it does affect my *usage* of
> > Python on redhat 6.1.
> >
> > Why don't #! scripts seem to work anymore?  #!/usr/bin/python and
> > #!/usr/bin/perl scripts don't work.  Error is
> 
> Someone's taken /usr/bin/python away?  Tried strace-ing it?
> 

Perl and Python both work if I do 'perl h2n' or 'python hello.py'. 
Interactive mode works fine.

> I presume /bin/sh scripts are still working (wouldn't like to think
> what happened if they went away).
> 

Sh scripts do work, as long as I remember to do ./script ;-).  I'm
running as root (but the same thing happens when I run as myself, too). 
However, this could be explained by the default behavour of exec(),
which states that if the kernel can't run a program, it execs sh and
hands it the program name in argv.


>   incidentally, asking why things are "left out of the language" is
>   a good sign that the asker is fairly clueless.

<but-what-about-things-left-out-of-the-kernel?>-ly y'rs,
Ivan
----------------------------------------------
Ivan Van Laningham
Callware Technologies, Inc.
http://www.pauahtun.org 
http://www.foretec.com/python/workshops/1998-11/proceedings.html
Army Signal Corps:  Cu Chi, Class of '70
Author:  Teach Yourself Python in 24 Hours




More information about the Python-list mailing list