[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: ["Eli Zaretskii" <address@hidden>] Re: configure: a.out.h vs nlist.h
From: |
Andreas Schwab |
Subject: |
Re: ["Eli Zaretskii" <address@hidden>] Re: configure: a.out.h vs nlist.h |
Date: |
06 Nov 2001 00:30:19 +0100 |
User-agent: |
Gnus/5.090003 (Oort Gnus v0.03) Emacs/21.1 |
Akim Demaille <address@hidden> writes:
|> | It seems like AC_FUNC_GETLOADAVG does not define NLIST_STRUCT any more,
|> | even though getloadavg.c needs it and it is documentated.
|> |
|> | Andreas.
|> |
|> | From: "Eli Zaretskii" <address@hidden>
|> | Subject: Re: configure: a.out.h vs nlist.h
|> | To: Andreas Schwab <address@hidden>
|> | Cc: address@hidden, address@hidden
|> | Reply-To: Eli Zaretskii <address@hidden>
|> |
|> | > From: Sam Steingold <address@hidden>
|> | > Date: 24 Oct 2001 16:24:28 -0400
|> | >
|> | > > > From: Sam Steingold <address@hidden>
|> | > > > Date: 24 Oct 2001 12:55:05 -0400
|> | > > >
|> | > > > On the current CVS emacs, I get this:
|> | > > > getloadavg.c:356:24: a.out.h: No such file or directory
|> | > > > after 'make distclean; ./configure; make bootstrap'
|> | > > > on Solaris 2.5.1, gcc 3.0, autoconf 2.52.
|> | > >
|> | > > That's weird: according to "cvs log", getloadavg.c didn't change since
|> | > > June 2000. Could you please look closer at this and see what changed
|> | > > since the last pretest you built (did you build any pretests on that
|> | > > machine?).
|> | > >
|> | > > Is it possible that this is the first time some of the tools are used,
|> | > > or a new version of some tool?
|> | >
|> | > I think I was not clear enough.
|> | > the problem is obviously with the recent changes in the configuration
|> | > process, i.e., the check for a.out.h vs nlist.h (see the subject line)
|> | > in configure. I suspect that when aclocal.m4 was dropped, the check
|> | > went away too, so the default include (a.out.h) is used now always.
|> |
|> | The problem is not with aclocal.m4, it's with the new Autoconf: its
|> | AC_FUNC_GETLOADAVG macro doesn't seem to define NLIST_STRUCT, and
|> | getloadavg.c needs that, at least on your system.
|> |
|> | Andreas, could you please look into this?
|> |
|> | ----------
|>
|> I don't think this was meant :(
|>
|> But looking at the code from 2.13:
|>
|> AC_CHECK_HEADER(nlist.h,
|> [AC_DEFINE(NLIST_STRUCT)
|> AC_CACHE_CHECK([for n_un in struct nlist], ac_cv_struct_nlist_n_un,
|> [AC_TRY_COMPILE([#include <nlist.h>],
|>
|> it seems useless: Just check HAVE_NLIST_H (the code in 2.50 does
|> define the symbol). As a matter of fact, looking at the version in
|> the fileutils, I see:
|>
|> # ifndef NLIST_STRUCT
|> # if HAVE_NLIST_H
|> # define NLIST_STRUCT
|> # endif
|> # endif
According to getloadavg.c, NLIST_STRUCT actually means more than that:
NLIST_STRUCT Include nlist.h, not a.out.h, and
the nlist n_name element is a pointer,
not an array.
|> Can't getloadavg.c be simplified instead? What is its master?
There is a file /gd/gnu/loadavg/getloadavg.c on fencepost which seems to
be the master, although the emacs version is even newer. The fileutils
version has to changes that do not appear in the other files:
* some locale support
* default NLIST_STRUCT from HAVE_NLIST_H
Otherwise it seems to be derived from an older version of the fencepost
file. The emacs version has two further changes from the fencepost
version:
* don't infer NLIST_STRUCT from system defines
* fix #ifdef FD_SETFD typo.
IMHO the changes should be merged.
Andreas.
--
Andreas Schwab "And now for something
address@hidden completely different."
SuSE Labs, SuSE GmbH, Schanzäckerstr. 10, D-90443 Nürnberg
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5