bug-automake
[Top][All Lists]
Advanced

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

Re: Bug in XFile.pm?


From: Alexandre Duret-Lutz
Subject: Re: Bug in XFile.pm?
Date: Mon, 01 Nov 2004 18:35:24 +0100
User-agent: Gnus/5.1003 (Gnus v5.10.3) Emacs/21.3.50 (gnu/linux)

I'm installing this on Automake HEAD.  
(It will propagate to Autoconf on the next `make update'.)

2004-11-01  Alexandre Duret-Lutz  <address@hidden>

        * lib/Automake/XFile.pm (lock): Make sure $ENV{'MAKEFLAGS'} exist
        before inspecting it; this fix "uninitialized value in concatenation"
        messages when flock fails.
        Report from Gary V. Vaughan.

Index: lib/Automake/XFile.pm
===================================================================
RCS file: /cvs/automake/automake/lib/Automake/XFile.pm,v
retrieving revision 1.8
diff -u -r1.8 XFile.pm
--- lib/Automake/XFile.pm       23 Oct 2003 14:29:22 -0000      1.8
+++ lib/Automake/XFile.pm       1 Nov 2004 17:32:33 -0000
@@ -1,4 +1,4 @@
-# Copyright (C) 2001, 2003 Free Software Foundation, Inc.
+# Copyright (C) 2001, 2003, 2004 Free Software Foundation, Inc.
 
 # This program is free software; you can redistribute it and/or modify
 # it under the terms of the GNU General Public License as published by
@@ -228,10 +228,12 @@
   # Admittedly this is a bit of a hack.
   if (!flock ($fh, $mode)
       && (!$!{ENOLCK}
-         || " -$ENV{'MAKEFLAGS'}" =~ / (-[BdeikrRsSw]*j|---?jobs)/))
+         || (exists $ENV{'MAKEFLAGS'}
+             && " -$ENV{'MAKEFLAGS'}" =~ / (-[BdeikrRsSw]*j|---?jobs)/)))
     {
       my $file = $fh->name;
-      fatal "cannot lock $file with mode $mode (perhaps you are running make 
-j on a lame NFS client?): $!";
+      fatal ("cannot lock $file with mode $mode "
+            . "(perhaps you are running make -j on a lame NFS client?): $!");
     }
 }
 

-- 
Alexandre Duret-Lutz





reply via email to

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