automake-patches
[Top][All Lists]
Advanced

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

XFile.pm


From: Akim Demaille
Subject: XFile.pm
Date: Thu, 23 Oct 2003 16:32:02 +0200
User-agent: Gnus/5.1002 (Gnus v5.10.2) Emacs/21.3 (gnu/linux)

Backporting from Autoconf.

Index: ChangeLog
from  Paul Eggert  <address@hidden>

        * lib/Automake/XFile.pm: Don't assume -j is solo.
        Issue a more-informative diagnostic.
        Problems reported by Eric Sunshine.

Index: lib/Automake/XFile.pm
===================================================================
RCS file: /cvs/automake/automake/lib/Automake/XFile.pm,v
retrieving revision 1.7
diff -u -u -r1.7 XFile.pm
--- lib/Automake/XFile.pm 1 Oct 2003 07:14:32 -0000 1.7
+++ lib/Automake/XFile.pm 23 Oct 2003 14:28:28 -0000
@@ -223,12 +223,15 @@
   # perl was not built with -Ud_flock.  Normally, this problem is harmless,
   # so ignore the ENOLCK errors that are reported in that situation,
   # However, if the invoker is using "make -j", the problem is not harmless,
-  # so report it in that case.  Admittedly this is a bit of a hack.
+  # so report it in that case, by inspecting MAKEFLAGS and looking for
+  # any arguments indicating that the invoker used -j.
+  # Admittedly this is a bit of a hack.
   if (!flock ($fh, $mode)
-      && (!$!{ENOLCK} || " $ENV{'MAKEFLAGS'}" =~ / (-j|--jobs)/))
+      && (!$!{ENOLCK}
+         || " -$ENV{'MAKEFLAGS'}" =~ / (-[BdeikrRsSw]*j|---?jobs)/))
     {
       my $file = $fh->name;
-      fatal "cannot lock $file with mode $mode: $!";
+      fatal "cannot lock $file with mode $mode (perhaps you are running make 
-j on a lame NFS client?): $!";
     }
 }
 




reply via email to

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