Re: Git 2.18: RUNTIME_PREFIX... is it working?
- From
- Jeff Hostetler <git@jeffhostetler.com>
- Date
- Jul 20, 2018, 14:29 UTC
- Message-ID
- <fc1c6b0b-e7a5-cbde-d927-8c1e1c4e9f11@jeffhostetler.com>
- In-Reply-To
- <20180719222613.GA7066@genre.crustytoothpaste.net>
On 7/19/2018 6:26 PM, brian m. carlson wrote:
Show 18 quoted lines
> On Wed, Jul 18, 2018 at 02:18:44PM +0200, Johannes Schindelin wrote: >> On Sat, 14 Jul 2018, brian m. carlson wrote: >>> I will say that at cPanel, we have a configuration where end users can >>> end up inside a mount namespace without /proc (depending on the >>> preferences of the administrator). However, it's easy enough for us to >>> simply build without RUNTIME_PREFIX if necessary. >>> >>> If we turn it on by default, it would be nice if we documented (maybe in >>> the Makefile) that it requires /proc on Linux for the benefit of other >>> people who might be in a similar situation. >> >> Is there *really* no other way on Linux to figure out the absolute path of >> the current executable than to open a pseudo file in the `/proc` file >> system? > > Nope, not that I'm aware of. You have to read the destination of > the /proc/PID/exe symlink. >
Getting the full path of the current executable is a very Windows thing. On most Unix-based systems it just isn't possible (even if Linux does have the /proc thing). Think about hard-links, for example. There just isn't a single canonical pathname for an inode.
Jeff