Re: gnulib getcwd patch needed for Solaris 10 getcwd
From:
Jim Meyering
Subject:
Re: gnulib getcwd patch needed for Solaris 10 getcwd
Date:
Thu, 22 Feb 2007 01:22:31 +0100
Paul Eggert <address@hidden> wrote:
> Jim Meyering <address@hidden> writes:
>
>> Why does your config.h define HAVE_PARTLY_WORKING_GETCWD
>> when using Sun C 5.8?
>
> Sorry, I don't know offhand. I don't currently have access to the
> affected machine but will try to get to it soon. It is Solaris 10
> x86, patched to about a month ago. I built it with a local (ufs) file
> system.
Bad timing. I was about to make a test release.
If anyone else has access to a Solaris 10 system (x86 or otherwise),
with Sun C, would you please try the latest snapshot?
http://meyering.net/cu/
> On Solaris 10, getcwd is a system call, and I suspect it's much better
> in common practice to try the syscall than to jump immediately to our
> own code, even if getcwd (NULL, 0) does not work as it does with
> glibc.
I ran a couple quick tests, and they suggest that there's nothing
special about Solaris 10's getcwd implementation (i.e., it's not
like the linux/glibc one). For example, /bin/pwd doesn't work
when a parent is unreadable. Does their system-provided
getcwd have something else to recommend it?
> In the meantime I've backed out the patch.
Thanks.