automake-patches
[Top][All Lists]
Advanced

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

FYI:


From: Alexandre Duret-Lutz
Subject: FYI:
Date: Wed, 02 Mar 2005 00:04:23 +0100
User-agent: Gnus/5.110003 (No Gnus v0.3) Emacs/21.3.50 (gnu/linux)

Right now, if you write

TESTS = \
   1.test \
   2.test \
   3.test \
## 4.test \
   5.test \
   6.test \
   7.test

Automake 1.9.5 discards the start of the definition and outputs only 

   5.test \
   6.test \
   7.test

in the Makefile.in.  

I'm installing the following fix on HEAD and branch-1-9.


2005-03-01  Alexandre Duret-Lutz  <address@hidden>

        * automake.in (read_am_file): Preserve backslashes preceding ##-lines.
        * tests/comment9.test: New file.
        * tests/Makefile.am (TESTS): Add comment9.test.
        Report from Julien Sopena.

Index: THANKS
===================================================================
RCS file: /cvs/automake/automake/THANKS,v
retrieving revision 1.266
diff -u -r1.266 THANKS
--- THANKS      26 Feb 2005 10:33:10 -0000      1.266
+++ THANKS      1 Mar 2005 22:56:52 -0000
@@ -122,6 +122,7 @@
 js pendry              address@hidden
 Juergen A. Erhard      address@hidden
 Juergen Keil           address@hidden
+Julien Sopena          address@hidden
 Karl Berry             address@hidden
 Karl Heuer             address@hidden
 Kelley Cook            address@hidden
Index: automake.in
===================================================================
RCS file: /cvs/automake/automake/automake.in,v
retrieving revision 1.1599
diff -u -r1.1599 automake.in
--- automake.in 27 Feb 2005 18:08:28 -0000      1.1599
+++ automake.in 1 Mar 2005 22:56:53 -0000
@@ -6003,6 +6003,9 @@
        if (/$IGNORE_PATTERN/o)
        {
            # Merely delete comments beginning with two hashes.
+
+           # Keep any backslash from the previous line.
+           $new_saw_bk = $saw_bk;
        }
        elsif (/$WHITE_PATTERN/o)
        {
Index: tests/Makefile.am
===================================================================
RCS file: /cvs/automake/automake/tests/Makefile.am,v
retrieving revision 1.583
diff -u -r1.583 Makefile.am
--- tests/Makefile.am   1 Mar 2005 22:17:30 -0000       1.583
+++ tests/Makefile.am   1 Mar 2005 22:56:53 -0000
@@ -98,6 +98,7 @@
 comment6.test \
 comment7.test \
 comment8.test \
+comment9.test \
 compile.test \
 compile_f90_c_cxx.test \
 compile_f_c_cxx.test \
Index: tests/comment9.test
===================================================================
RCS file: tests/comment9.test
diff -N tests/comment9.test
--- /dev/null   1 Jan 1970 00:00:00 -0000
+++ tests/comment9.test 1 Mar 2005 22:56:53 -0000
@@ -0,0 +1,54 @@
+#! /bin/sh
+# Copyright (C) 2005  Free Software Foundation, Inc.
+#
+# This file is part of GNU Automake.
+#
+# GNU Automake is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 2, or (at your option)
+# any later version.
+#
+# GNU Automake is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with Automake; see the file COPYING.  If not, write to
+# the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+# Boston, MA 02111-1307, USA.
+
+# Make sure ##-comments are ignored in variable definitions.
+# Report from Julien Sopena.
+
+. ./defs || exit 1
+
+set -e
+
+cat > Makefile.am << 'EOF'
+TESTS = \
+   1.test \
+   2.test \
+   3.test \
+## 4.test \
+   5.test \
+   6.test \
+   7.test
+EOF
+
+$ACLOCAL
+$AUTOMAKE
+
+sed -n -e '/^TESTS =.*\\$/ {
+   :loop
+   p
+   n
+   /\\$/ b loop
+   p
+   n
+   }' -e '/^TESTS =/ p' Makefile.in > tests
+
+grep '3\.test' tests
+grep '&&' tests && exit 1
+grep '4\.test' tests && exit 1
+grep '5\.test' tests

-- 
Alexandre Duret-Lutz





reply via email to

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