From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 20677 invoked by alias); 8 Aug 2004 07:39:19 -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 20669 invoked from network); 8 Aug 2004 07:39:18 -0000 Received: from unknown (HELO licht.localdomain) (217.235.253.94) by sourceware.org with SMTP; 8 Aug 2004 07:39:18 -0000 Received: from licht.localdomain (localhost.localdomain [127.0.0.1]) by licht.localdomain (8.12.5/8.12.5) with ESMTP id i787dQlt002118; Sun, 8 Aug 2004 09:39:26 +0200 Received: (from pes@localhost) by licht.localdomain (8.12.5/8.12.5/Submit) id i787dPN4002116; Sun, 8 Aug 2004 09:39:25 +0200 From: Peter Schauer Message-Id: <200408080739.i787dPN4002116@licht.localdomain> Subject: Re: [RFC/AIX] xm-aix4.h - Remove alloca #pragma To: brobecker@gnat.com (Joel Brobecker) Date: Sun, 08 Aug 2004 07:39:00 -0000 Cc: gdb-patches@sources.redhat.com, cagney@redhat.com, kevinb@redhat.com In-Reply-To: <20040808045407.GF24160@gnat.com> from "Joel Brobecker" at Aug 07, 2004 09:54:07 PM MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2004-08/txt/msg00240.txt.bz2 Could you please try to include malloc.h instead ? > config/xm-aix4.h contains the following definition: > > | /* The IBM compiler requires this in order to properly compile alloca(). */ > | #pragma alloca > > I just checked with an IBM C compiler, and indeed, we need this pragma > or the link will fail. Yuck! Can we solve this problem this way? > > . Add a check in configure to link a program using alloca. > . If pass, we're done. > . Try again with #pragma alloca > . If pass, then define #USE_PRAGMA_ALLOCA, or HAVE_PRAGMA_ALLOCA > or something like this > . Some other ways to get alloca??? > . If fail, then abort configure, we need alloca. > > Then add something like this in defs: > > #ifdef USE_PRAGMA_ALLOCA > #pragma alloca > #endif > > -- > Joel > -- Peter Schauer Peter.Schauer@mytum.de