1999-04-27 Tom Tromey <tromey@cygnus.com>
+ * automake.in (MACRO_PATTERN): Allow digits and `_' to start a
+ macro name.
+ (check_canonical_spelling): Don't insert `AM' before macro name
+ (reverts Alexandre's 1999-04-27 patch).
+ * automake.texi: Reverted documentation change for `AM' patch.
+
* automake.in (handle_lib_objects_cond): Prefer `$1' over `\1'.
Minor rewrite for clarity.
(check_canonical_spelling): Prefer `$1' over `\1'.
$COMMENT_PATTERN = "^#";
$RULE_PATTERN = "^([\$a-zA-Z_.][-.a-zA-Z0-9_(){}/\$]*) *:([^=].*|)\$";
$SUFFIX_RULE_PATTERN = "^\\.([a-zA-Z]+)\\.([a-zA-Z]+)\$";
-$MACRO_PATTERN = "^([A-Za-z][A-Za-z0-9_]*)[ \t]*([:+]?)=[ \t]*(.*)\$";
+$MACRO_PATTERN = "^([A-Za-z0-9_]+)[ \t]*([:+]?)=[ \t]*(.*)\$";
$BOGUS_MACRO_PATTERN = "^([^ \t]*)[ \t]*([:+]?)=[ \t]*(.*)\$";
$GNITS_VERSION_PATTERN = "[0-9]+\\.[0-9]+([a-z]|\\.[0-9]+)?";
$IF_PATTERN = "^if[ \t]+\([A-Za-z][A-Za-z0-9_]*\)[ \t]*\(#.*\)?\$";
local ($xname, $xt);
($xname = $name) =~ tr/A-Za-z0-9_/_/c;
- $xname =~ s/^([0-9_])/AM$1/;
if ($xname ne $name)
{
local ($xt);
@code{sniff-glue}, the derived variable name would be
@code{sniff_glue_SOURCES}, not @code{sniff-glue_SOURCES}.
-Additionally, because some versions of make require macro names to start
-with a @emph{letter}, when a name that starts with a non-letter
-character is canonicalized, the characters @code{AM} are prepended to
-it. Therefore, if a program is named @code{123test} or @code{_foo}, the
-derived variable names would be @code{AM123test_SOURCES} or
-@code{AM_foo_SOURCES}. Note that, even if such a program name would not
-appear in the beginning of the name of the macro, @code{AM} is still
-inserted, i.e., use @code{EXTRA_AM123test_SOURCES}, not
-@code{EXTRA_123test_SOURCES}.
-
@node Examples, Invoking Automake, Generalities, Top
@chapter Some example packages