From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17109 invoked by alias); 10 Sep 2010 14:01:23 -0000 Received: (qmail 17101 invoked by uid 22791); 10 Sep 2010 14:01:23 -0000 X-SWARE-Spam-Status: No, hits=1.6 required=5.0 tests=AWL,BAYES_00,KAM_STOCKTIP,MSGID_MULTIPLE_AT X-Spam-Check-By: sourceware.org Received: from mailhost.u-strasbg.fr (HELO mailhost.u-strasbg.fr) (130.79.200.158) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Fri, 10 Sep 2010 14:01:16 +0000 Received: from md2.u-strasbg.fr (md2.u-strasbg.fr [IPv6:2001:660:2402::187]) by mailhost.u-strasbg.fr (8.14.3/jtpda-5.5pre1) with ESMTP id o8AE1CcK094267 for ; Fri, 10 Sep 2010 16:01:13 +0200 (CEST) (envelope-from pierre.muller@ics-cnrs.unistra.fr) Received: from mailserver.u-strasbg.fr (ms5.u-strasbg.fr [IPv6:2001:660:2402:d::14]) by md2.u-strasbg.fr (8.14.4/jtpda-5.5pre1) with ESMTP id o8AE1Cil067791 for ; Fri, 10 Sep 2010 16:01:12 +0200 (CEST) (envelope-from pierre.muller@ics-cnrs.unistra.fr) Received: from d620muller (gw-ics.u-strasbg.fr [130.79.210.225]) (user=mullerp mech=LOGIN) by mailserver.u-strasbg.fr (8.14.4/jtpda-5.5pre1) with ESMTP id o8AE1CvY078162 (version=TLSv1/SSLv3 cipher=RC4-MD5 bits=128 verify=NO) for ; Fri, 10 Sep 2010 16:01:12 +0200 (CEST) (envelope-from pierre.muller@ics-cnrs.unistra.fr) From: "Pierre Muller" To: Subject: [RFA 3/5] New patches to support --enable-targets=all for mingw64 Date: Fri, 10 Sep 2010 14:55:00 -0000 Message-ID: <003c01cb50f0$a440e2c0$ecc2a840$@muller@ics-cnrs.unistra.fr> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2010-09/txt/msg00221.txt.bz2 I tried to compile GDB with --enable-targets=all for x86_64-w64-mingw32 target. As 'long' type is 4-byte while pointer type is 8-byte, this target is quite sensitive to so 'dirty' code lying around like casting 'long' or 'unsigned long' to pointers... I had to fix several sources to be able to successfully compile GDB with those configuration options. 3) Change some types from 'long' to 'CORE_ADDRESS', if they could carry pointers. in coffread.c Pierre Muller Pascal language support maintainer for GDB 2010-09-10 Pierre Muller * coffread.c (struct coff_symbol): Change c_value type from `long' to `CORE_ADDRESS' as it might contain target addresses. Index: src/gdb/coffread.c =================================================================== RCS file: /cvs/src/src/gdb/coffread.c,v retrieving revision 1.109 diff -u -p -r1.109 coffread.c --- src/gdb/coffread.c 9 Aug 2010 19:42:46 -0000 1.109 +++ src/gdb/coffread.c 9 Sep 2010 16:39:57 -0000 @@ -131,7 +131,7 @@ struct coff_symbol char *c_name; int c_symnum; /* symbol number of this entry */ int c_naux; /* 0 if syment only, 1 if syment + auxent, etc */ - long c_value; + CORE_ADDR c_value; int c_sclass; int c_secnum; unsigned int c_type;