Hi Sam,

* Sam Sirlin wrote on Wed, May 31, 2006 at 01:11:49AM CEST:
>    From: Ralf Wildenhues <[EMAIL PROTECTED]>

>    Is your script home-grown or does it have some wider usage?  What does
>    it output upon
>      dirname -- /
> 
> It's old code from SVr2, so it may be lurking around on old systems. I
> probably grabbed it someday before sun had added it in (sun4?). 
> 
> kalessin{sam} > old_dirname -- /
> .
> 
> sun solaris 9 has apparently a shell script  v 1.7  (SVr4) that
> behaves more like gnu:

> I've tried this and it works with the new configure.

Good, thanks for checking.  I have applied the following patch to
Autoconf.

Cheers,
Ralf

        * lib/m4sugar/m4sh.m4 (_AS_DIRNAME_PREPARE): Check whether
        `dirname -- /' returns `/', for SunOS dirname scripts that escaped.
        Report by Sam Sirlin <[EMAIL PROTECTED]>.

Index: lib/m4sugar/m4sh.m4
===================================================================
RCS file: /cvsroot/autoconf/autoconf/lib/m4sugar/m4sh.m4,v
retrieving revision 1.188
diff -u -r1.188 m4sh.m4
--- lib/m4sugar/m4sh.m4 26 May 2006 22:29:50 -0000      1.188
+++ lib/m4sugar/m4sh.m4 30 May 2006 23:23:59 -0000
@@ -755,7 +755,7 @@
 # _AS_DIRNAME_PREPARE
 # --------------------
 m4_defun([_AS_DIRNAME_PREPARE],
-[if (dirname -- /) >/dev/null 2>&1; then
+[if (as_dir=`dirname -- /` && test "$as_dir" = /) >/dev/null 2>&1; then
   as_dirname=dirname
 else
   as_dirname=false


_______________________________________________
Bug-coreutils mailing list
Bug-coreutils@gnu.org
http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to