automake
[Top][All Lists]
Advanced

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

Patch to allow spaces before double hashes


From: Pavel Roskin
Subject: Patch to allow spaces before double hashes
Date: Fri, 11 May 2001 11:26:56 -0400 (EDT)

Hello!

It seems to be a pointless requirement that the comments in Makefile.am
begin strictly at the line start, even if they don't appear in
Makefile,in.

It can often be useful to place a comment as near as possible to the line
being commented but preserve the indentation. It should now be possible
with the proposed patch.

Automake should probably warn about indented comments that go to
Makefile.in, as they may be non-portable. I just saw a report in
address@hidden that Compaq Tru64 UNIX V5.1 doesn't like '&' in such
comments, most likely because they are actully fed to the shell. But this
is out of scope of the proposed patch.

ChangeLog:
        * automake.in ($IGNORE_PATTERN): Allow spaces before double hash.

_____________________________
--- automake.in
+++ automake.in
@@ -111,7 +111,7 @@
 my $pkgdata_dir = "@datadir@/@PACKAGE@";

 # String constants.
-my $IGNORE_PATTERN = '^##([^#\n].*)?\n';
+my $IGNORE_PATTERN = '^\s*##([^#\n].*)?\n';
 my $WHITE_PATTERN = '^\s*$';
 my $COMMENT_PATTERN = '^#';
 my $TARGET_PATTERN='[$a-zA-Z_.][-.a-zA-Z0-9_(){}/$]*';
_____________________________

Regards,
Pavel Roskin




reply via email to

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