Mail Archives: djgpp-workers/2001/07/07/02:37:28
> From: "Mark E." <snowball3 AT bigfoot DOT com>
> Date: Fri, 6 Jul 2001 15:00:54 -0400
>
> 9866 One common historical implementation is that the execl(), execv(),
> execle( ), and execve() functions return an [ENOEXEC] error for any file not
> recognizable as executable, including a shell script. When the execlp( ) and
> execvp( ) functions encounter such a file, they assume the file to be a shell
> script and invoke a known command interpreter to interpret such files. This
> is now required by IEEE Std 1003.1-200x. These implementations of execvp( )
> and execlp( ) only give the error in the rare case of a problem with the
> command interpreterexecutable file.
>
> I think this new requirement can be applied to djgpp by having script_exec
> use SHELL for the program to run if it can't find a hash bang line.
script_exec already does that, except that it invokes command.com, not
the value of $SHELL.
Note that the Posix draft makes a distinction between execl, execv,
execle and execve on the one side, and execlp and execvp on the
other. AFAICS, dosexec doesn't handle these cases (and their
respective spawn* brethren) differently.
- Raw text -