From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6767 invoked by alias); 13 Jan 2005 04:04:37 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 6716 invoked from network); 13 Jan 2005 04:04:31 -0000 Received: from unknown (HELO dair.pair.com) (209.68.1.49) by sourceware.org with SMTP; 13 Jan 2005 04:04:31 -0000 Received: (qmail 46082 invoked by uid 20157); 13 Jan 2005 04:04:31 -0000 Date: Thu, 13 Jan 2005 04:04:00 -0000 From: Hans-Peter Nilsson X-X-Sender: hp@dair.pair.com To: Andrew Cagney cc: gdb-patches@sources.redhat.com Subject: Re: [commit/sim] Add common/common.m4; Was: [commit/sim] switch autoconf 2.59 In-Reply-To: <41E55AB7.1060802@gnu.org> Message-ID: References: <41DF55E5.7010307@gnu.org> <41E43F98.1010601@gnu.org> <41E47C74.3050607@gnu.org> <41E5501A.3000907@gnu.org> <41E55AB7.1060802@gnu.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-SW-Source: 2005-01/txt/msg00098.txt.bz2 On Wed, 12 Jan 2005, Andrew Cagney wrote: > I've also committed the attached. It gets around the SIM_AC_COMMON > problem by inlining the macro's contents. > > Your turn :-) With current sources (after adding common.m4), CY_GNU_GETTEXT is not defined before use (checkout, configury and build as before): ... configure: configuring in frv ... /n/asic/slask/hp/fixsimbreakage/src/sim/frv/configure: CY_GNU_GETTEXT: command not found ... (further problems ignored.) The bug seen above can be fixed by sincluding aclocal.m4 before common.m4, putting the definition before the call. (After that I then see some disturbing warnings when compiling sim/frv/sem.c, but those aren't any fault of the configury at least, so that's to be considered a success.) I'm not sure why you didn't just sinclude common.m4 from aclocal.m4 and why you didn't remove SIM_AC_COMMON from aclocal.m4. Therefore I don't know how you want the above and the worry below actually fixed and so I'll pass back the "your turn". ;-) The biggest problem is that I don't understand why breaking out SIM_AC_COMMON to common.m4 should help at all, but it does. Editing aclocal:SIM_AC_COMMON to look *exactly* like common.a4 (or indeed leaving it the same; the ifelse does the same) and this diff to sim/frv/configure.ac (note order of sincludes assumed fixed as per above): --- configure.ac.fixed Thu Jan 13 04:25:38 2005 +++ configure.ac Thu Jan 13 04:33:45 2005 @@ -3,7 +3,7 @@ AC_PREREQ(2.59)dnl AC_INIT(Makefile.in) sinclude(../common/aclocal.m4) -sinclude(../common/common.m4) +SIM_AC_COMMON SIM_AC_OPTION_ENDIAN(BIG_ENDIAN) SIM_AC_OPTION_ALIGNMENT(STRICT_ALIGNMENT) *should* do the same. But it doesn't; it seems for example AC_CANONICAL_SYSTEM and AC_PROG_CC aren't called (and from that point configury derails causing declarations and macros wrong and missing at compile time). Weird. A prominent note that the contents of common.m4 must not be wrapped and called as a macro seems in order. The comment at the top of common.m4 "autoconf.info says this should be called right after AC_INIT" doesn't tell the important part of the story. brgds, H-P