[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Problem with autoscan
From: |
Akim Demaille |
Subject: |
Problem with autoscan |
Date: |
12 Jun 2001 10:56:02 +0200 |
User-agent: |
Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Copyleft) |
I was about to address Paul's suggestion for sys/types.h when I saw
that there were duplicate entries in some of the autoscan tables.
In order to catch them, I added this:
Index: autoscan.in
===================================================================
RCS file: /cvs/autoconf/autoscan.in,v
retrieving revision 1.48
diff -u -u -r1.48 autoscan.in
--- autoscan.in 2001/06/12 08:40:03 1.48
+++ autoscan.in 2001/06/12 08:46:26
@@ -213,6 +213,8 @@
}
my $word = $1;
my $macro = $2 || $generic_macro{$kind};
+ warn "$file: $.: duplicate entry: $word\n"
+ if exists $macro{$kind}{$word} && $macro{$kind}{$word} ne $macro;
$macro{$kind}{$word} = $macro;
}
close(TABLE);
and then, the initialization of autoscan produces this:
~/src/fileutils-4.1 % ../ace/autoscan -A $ace nostromo 10:48
/home/lrde/prof/akim/src/ace/acfunctions: 74: duplicate entry: bzero
/home/lrde/prof/akim/src/ace/acfunctions: 87: duplicate entry: fseeko
/home/lrde/prof/akim/src/ace/acfunctions: 92: duplicate entry: getgroups
/home/lrde/prof/akim/src/ace/acfunctions: 97: duplicate entry: getloadavg
/home/lrde/prof/akim/src/ace/acfunctions: 117: duplicate entry: memchr
/home/lrde/prof/akim/src/ace/acfunctions: 118: duplicate entry: memmove
/home/lrde/prof/akim/src/ace/acfunctions: 120: duplicate entry: memset
/home/lrde/prof/akim/src/ace/acfunctions: 152: duplicate entry: strftime
/home/lrde/prof/akim/src/ace/acfunctions: 160: duplicate entry: strtod
/home/lrde/prof/akim/src/ace/acfunctions: 169: duplicate entry: utime
/home/lrde/prof/akim/src/ace/acfunctions: 172: duplicate entry: vprintf
/home/lrde/prof/akim/src/ace/acheaders: 42: duplicate entry: float.h
/home/lrde/prof/akim/src/ace/acheaders: 61: duplicate entry: stddef.h
/home/lrde/prof/akim/src/ace/acheaders: 64: duplicate entry: stdlib.h
/home/lrde/prof/akim/src/ace/acheaders: 65: duplicate entry: string.h
/home/lrde/prof/akim/src/ace/acheaders: 84: duplicate entry: sys/wait.h
it was meant to catch things like
~/src/ace % grep sys/wait.h acheaders nostromo 10:49
sys/wait.h AC_HEADER_SYS_WAIT
sys/wait.h
(the later meaning using AC_CHECK_HEADERS).
This is really an error, as you should use AC_HEADER_SYS_WAIT, and not
AC_CHECK_HEADERS. This is what the patch above meant to catch. Worse
yet: it is the latest definition that wins, i.e., on the fileutils,
autoscan suggests AC_CHECK_HEADERS(sys/wait.h), and will not consider
AC_HEADER_SYS_WAIT. Because to one entity you can map *one* macro,
not several.
But...
But the first entry, bzero, is somewhat different:
~/src/ace % grep bzero acfunctions nostromo 10:50
bzero AC_HEADER_STDC
bzero
autoscan is expected to suggest running both AC_CHECK_FUNCS(bzero),
and AC_HEADER_STDC, which is a different story.
So? What is the right behavior? Should autoscan be extended to
support several macros per `word'? Should these issues be handled
some other way?
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Problem with autoscan,
Akim Demaille <=