From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 560 invoked by alias); 23 Jan 2013 14:58:22 -0000 Received: (qmail 550 invoked by uid 22791); 23 Jan 2013 14:58:21 -0000 X-SWARE-Spam-Status: No, hits=-7.7 required=5.0 tests=AWL,BAYES_00,KHOP_RCVD_UNTRUST,KHOP_THREADED,RCVD_IN_DNSWL_HI,RCVD_IN_HOSTKARMA_W,RP_MATCHES_RCVD,SPF_HELO_PASS X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Wed, 23 Jan 2013 14:58:13 +0000 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r0NEwAjW016700 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Wed, 23 Jan 2013 09:58:10 -0500 Received: from [127.0.0.1] (ovpn01.gateway.prod.ext.ams2.redhat.com [10.39.146.11]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r0NEw98c023340; Wed, 23 Jan 2013 09:58:09 -0500 Message-ID: <50FFFA80.8020001@redhat.com> Date: Wed, 23 Jan 2013 14:58:00 -0000 From: Pedro Alves User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130110 Thunderbird/17.0.2 MIME-Version: 1.0 To: Robert CC: gdb@sourceware.org Subject: Re: Building gdb for Android using Android-ndk References: <50FFAD68.2050901@mailueberfall.de> <50FFE822.5010309@redhat.com> <50FFF99E.6010800@mailueberfall.de> In-Reply-To: <50FFF99E.6010800@mailueberfall.de> Content-Type: text/plain; charset=windows-1252 Content-Transfer-Encoding: 7bit Mailing-List: contact gdb-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-owner@sourceware.org X-SW-Source: 2013-01/txt/msg00075.txt.bz2 On 01/23/2013 02:28 PM, Robert wrote: >> You're building a gdb that runs on Android? Or you want a GDBserver >> that runs on Android, but debug from your x86_64 Ubuntu host? > > I am trying to build a standalone version of gdb that runs directly on > the device. Ack. I don't ever recall seeing patches to port the various subprojects in gdb (bfd, libiberty, gdb itself, etc.), except gdbserver, which always runs on the target, to Android/bionic though. You're likely to hit problems that would need porting work. It is coincidence that the error just occurs in the > gdbserver subproject. I am not aware of the internal dependencies of gdb > - may be one can simply disable the gdbserver subproject? gdbserver should build for Android. So the cross scenario we know works. > > arm-linux-androideabi-gcc -c -DHAVE_CONFIG_H -g -O2 -I. -I./../include > -W -Wall -Wwrite-strings -Wc++-compat -Wstrict-prototypes -pedantic > ./getpagesize.c -o getpagesize.o > ./getpagesize.c:64:1: error: redefinition of 'getpagesize' > /opt/android-standalone-toolchain/bin/../sysroot/usr/include/unistd.h:162:23: > note: previous definition of 'getpagesize' was here > > I checked the log and noticed that the system checks that executed the > first time when I execute "make" contains several lines with > "checking for getpagesize... no". > > I uploaded the complete make log here: http://pastebin.com/v3etd3Sa Right, so the build is failing while building libiberty (primarily a host abstraction library). I'm afraid it looks like someone needs to step up and do some porting work. Looks like you found an itch to scratch. ;-) -- Pedro Alves