From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6666 invoked by alias); 26 Feb 2003 03:08:48 -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 6659 invoked from network); 26 Feb 2003 03:08:48 -0000 Received: from unknown (HELO crack.them.org) (65.125.64.184) by 172.16.49.205 with SMTP; 26 Feb 2003 03:08:48 -0000 Received: from nevyn.them.org ([66.93.61.169] ident=mail) by crack.them.org with asmtp (Exim 3.12 #1 (Debian)) id 18ntpM-0000Ur-00 for ; Tue, 25 Feb 2003 23:09:56 -0600 Received: from drow by nevyn.them.org with local (Exim 3.36 #1 (Debian)) id 18nrw5-0000XN-00 for ; Tue, 25 Feb 2003 22:08:45 -0500 Date: Wed, 26 Feb 2003 03:08:00 -0000 From: Daniel Jacobowitz To: gdb-patches@sources.redhat.com Subject: Re: [rfa] HAVE_UINTPTR_T Message-ID: <20030226030845.GA1322@nevyn.them.org> Mail-Followup-To: gdb-patches@sources.redhat.com References: <200302260126.h1Q1Qd715234@duracef.shout.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <200302260126.h1Q1Qd715234@duracef.shout.net> User-Agent: Mutt/1.5.1i X-SW-Source: 2003-02/txt/msg00691.txt.bz2 On Tue, Feb 25, 2003 at 07:26:39PM -0600, Michael Elizabeth Chastain wrote: > Draft #2. I changed the variable to HAVE_UINTPTR_T, and I changed > AC_TRY_RUN to AC_TRY_COMPILE. I re-tested with and without > uintptr_t in /usr/include/stdint.h to hit both paths. > > I don't show diffs for regenerated 'configure'. I regenerated > 'configure' with stock autoconf 2.13 from ftp.gnu.org. > > Again, this is so that the gdb build can do something better when > it needs uintptr_t and doesn't have it (pr gdb/660). My notion of > 'something better' is going to be to spit out a better error message, > not to actually work. Somebody has to have a really old libc > (more than 3 years old) to get this message, but with millions of > users, some people do. > > OK to commit? More autoconf nits: > +dnl See if C library supports "uintptr_t" type. > +dnl AC_CHECK_TYPE is not enough because this type lives in a header file. > + > +AC_MSG_CHECKING(for uintptr_t in C library) > +AC_CACHE_VAL(gdb_cv_have_uintptr_t, Use AC_CACHE_CHECK. > +[AC_TRY_COMPILE([#include ], > + [uintptr_t foo = 0; > + return foo;], > + gdb_cv_have_uintptr_t=yes, > + gdb_cv_have_uintptr_t=no)]) > +AC_MSG_RESULT($gdb_cv_have_uintptr_t) > +if test $gdb_cv_have_uintptr_t = yes; then > + AC_DEFINE(HAVE_UINTPTR_T) You should probably use the multi-argument form of AC_DEFINE. -- Daniel Jacobowitz MontaVista Software Debian GNU/Linux Developer