bug-make
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in builtin function abspath (again)


From: Eli Zaretskii
Subject: Re: Bug in builtin function abspath (again)
Date: Wed, 31 May 2006 23:13:20 +0300

> From: Boris Kolpackov <address@hidden>
> Date: Wed, 31 May 2006 07:48:12 +0000 (UTC)
> 
> I just checked the page for realpath in SUS and I don't see anything
> that implies this. My understanding that all components of the path
> must exist.

So it's probably system-dependent.

> > Yes, that seems to be the meaning.  But on platforms where there's no
> > realpath, we currently use abspath that doesn't care whether that
> > directory exists.  Since Joe Random Hacker might not know whether her
> > Make was built with or without realpath (and the docs don't even tell
> > that realpath falls back on abspath), we should try to emulate
> > realpath as close as we can, I think.
> >
> > I also thought about writing an emulation for realpath by using
> > readlink.  Unless I'm missing something, that shouldn't be too hard.
> 
> Here is the documentation for realpath and abspath from GNU make manual:

Well, granted, I've read this before I wrote the above.  Note that
this documentation doesn't say what happens on systems where there's
no realpath, and most users won't know whether their binary has or
doesn't have it.

> I guess for platforms without realpath, we can emulate it as
> func_wildcard (func_abspath (...)) rather than just func_abspath (...).

Yes, that'd be nice, I think.  But using readlink is better (albeit
more complicated) because it will then resolve symlinks on systems
that have them.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]