From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 48592 invoked by alias); 30 Oct 2015 05:25:09 -0000 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 Received: (qmail 48581 invoked by uid 89); 30 Oct 2015 05:25:08 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-4.1 required=5.0 tests=AWL,BAYES_00,RP_MATCHES_RCVD,SPF_HELO_PASS autolearn=ham version=3.3.2 X-HELO: mx1.redhat.com Received: from mx1.redhat.com (HELO mx1.redhat.com) (209.132.183.28) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES256-GCM-SHA384 encrypted) ESMTPS; Fri, 30 Oct 2015 05:25:08 +0000 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (Postfix) with ESMTPS id 2609AA0BA6 for ; Fri, 30 Oct 2015 05:25:07 +0000 (UTC) Received: from pinnacle.lan (ovpn-113-191.phx2.redhat.com [10.3.113.191]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id t9U5P6KJ028062 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA256 bits=256 verify=NO) for ; Fri, 30 Oct 2015 01:25:07 -0400 Date: Fri, 30 Oct 2015 12:06:00 -0000 From: Kevin Buettner To: gdb-patches@sourceware.org Subject: Re: [PATCH] gdb.dwarf2: Define and use gdb_target_symbol_prefix for symbol prefixes Message-ID: <20151029222505.3bb590b9@pinnacle.lan> In-Reply-To: <20151029212509.438b5642@pinnacle.lan> References: <20151029212509.438b5642@pinnacle.lan> MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-IsSubscribed: yes X-SW-Source: 2015-10/txt/msg00749.txt.bz2 On Thu, 29 Oct 2015 21:25:09 -0700 Kevin Buettner wrote: > Some of the tests in gdb.dwarf2 which use Dwarf::assemble refer to > (minimal/linker) symbols created in the course of building a small > test program. Some targets use a prefix such as underscore ("_") on > these symbols. Many of the tests in gdb.dwarf2 do not take this into > account. As a consequence, these tests fail to build, resulting > either in failures or untested testcases. Several of the .S files in gdb.dwarf2 have the same problem. E.g. when linking the test case for gdb.dwarf2/method-ptr.exp, I see a linker error "undefined reference to `main'". It appears that crt0 is generating a reference to _main, but the .S file only provides a reference to main. Any thoughts on what to do about this? (It occurs to me that I could define both _main and main in the .S file, but this doesn't solve the problem should some other prefix be used instead.) Kevin