[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ff13bc9a1003251400ted1993ao73c15ee86e3e717a@mail.gmail.com>
Date: Thu, 25 Mar 2010 22:00:49 +0100
From: Luca Barbieri <luca.barbieri@...il.com>
To: Olaf van der Spek <olafvdspek@...il.com>
Cc: drepper@...il.com, linux-kernel@...r.kernel.org
Subject: Re: execve() returns ENOENT when ld-linux.so isn't found
POSIX 2008 says, for exec*:
[ENOENT]
A component of path or file does not name an existing file or path
or file is an empty string.
[ENOEXEC]
The new process image file has the appropriate access permission
but has an unrecognized format.
[EINVAL]
The new process image file has appropriate privileges and has a
recognized executable binary format, but the system does not support
execution of a file with this format.
None of these perfectly fit, but EINVAL seems the closest.
Note that ENOENT only specifies that the error happens for "not found"
problems in the function argument itself, so it is not really more
correct than the others.
Linux also defines ELIBACC (for a.out I believe):
#define ELIBACC 79 /* Can not access a needed shared library */
This also seems a possible candidate.
Not sure if it is safe to change this though, or what other systems do.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists