Re: Porting pam to Solaris, HP-UX, others

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

 



On Wed, Dec 13, 2000 at 10:55:40AM +0000, David Lee wrote:
> None of the Solaris "test(1*)" have the "-e" option (although it is there
> in the csh built-in test).  Same probably applies to the much of the rest
> of the UNIX world outside Linux. 
> 
> I think "-r" is an appropriate substitute.  (It works both from a clean
> distribution, and also after a "make clean";  that should cover all cases
> but the most pathological.) 

This is not quite true.  I *think* that /bin/test is quite portable.
(/bin -> /usr/bin in Solaris)...

   % /bin/test -e /foo && echo yes || echo no
   no

   % /bin/test -e /tmp && echo yes || echo no
   yes

Not that this really matters, but /usr/xpg4/bin/sh works much more like
/bin/sh on other platforms.  That is, it is really ksh.

Mike





[Index of Archives]     [Fedora Users]     [Kernel]     [Red Hat Install]     [Linux for the blind]     [Gimp]

  Powered by Linux