[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
28-fyi-clarify-am-line-error.patch
From: |
Akim Demaille |
Subject: |
28-fyi-clarify-am-line-error.patch |
Date: |
Sun, 21 Oct 2001 20:11:49 +0200 |
Index: ChangeLog
from Akim Demaille <address@hidden>
* automake.in (am_line_error): Clarify.
Index: automake.in
--- automake.in Sun, 21 Oct 2001 14:35:00 +0200 akim
+++ automake.in Sun, 21 Oct 2001 14:43:48 +0200 akim
@@ -8064,37 +8064,41 @@ sub am_file_error
am_print_error ("$file: ", @args);
}
-sub am_line_error
+# &am_line_error ($SYMBOL or $LINE, @ARGS)
+# ----------------------------------------
+# Report an error about $SYMBOL. The error message is composed of the
+# @ARGS, and try to find the location of the error of $SYMBOL.
+sub am_line_error ($@)
{
my ($symbol, @args) = @_;
if ($symbol && "$symbol" ne '-1')
{
- my $file = "${am_file}.am";
-
+ my $where;
if ($symbol =~ /^\d+$/)
{
- # SYMBOL is a line number, so just add the colon.
- $file .= ':' . $symbol;
+ # SYMBOL is a line number, then it must be a Makefile.am.
+ $where = "${am_file}.am:$symbol";
}
elsif (defined $var_line{$symbol})
{
# SYMBOL is a variable defined in Makefile.am, so add the
# line number we saved from there.
- $file .= ':' . $var_line{$symbol};
+ $where = "${am_file}.am:$var_line{$symbol}";
}
elsif (defined $configure_vars{$symbol})
{
# SYMBOL is a variable defined in configure.ac, so add the
# appropriate line number.
- $file = $configure_vars{$symbol};
+ $where = $configure_vars{$symbol};
}
else
{
# Couldn't find the line number.
+ $where = "${am_file}.am";
}
- am_print_error ("$file: ", @args);
+ am_file_error ($where, @args);
}
else
{
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- 28-fyi-clarify-am-line-error.patch,
Akim Demaille <=