From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12591 invoked by alias); 12 Aug 2004 13:33:08 -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 12583 invoked from network); 12 Aug 2004 13:33:07 -0000 Received: from unknown (HELO maynard.mail.mindspring.net) (207.69.200.243) by sourceware.org with SMTP; 12 Aug 2004 13:33:07 -0000 Received: from user-119a90a.biz.mindspring.com ([66.149.36.10] helo=berman.michael-chastain.com) by maynard.mail.mindspring.net with esmtp (Exim 3.33 #1) id 1BvFha-00070Y-00; Thu, 12 Aug 2004 09:33:06 -0400 Received: from mindspring.com (localhost [127.0.0.1]) by berman.michael-chastain.com (Postfix) with SMTP id 141294B102; Thu, 12 Aug 2004 09:33:07 -0400 (EDT) Date: Thu, 12 Aug 2004 13:33:00 -0000 From: Michael Chastain To: jjohnstn@redhat.com Subject: Re: [RFA]: Fix for pending breakpoints in manually loaded/unloaded shlibs Cc: gdb-patches@sources.redhat.com Message-ID: <411B7192.nailNVT199XPP@mindspring.com> References: <41191D71.60204@redhat.com> <4119D461.nailB1A1E2BLH@mindspring.com> <411A3E5D.7060309@redhat.com> In-Reply-To: <411A3E5D.7060309@redhat.com> User-Agent: nail 10.8 6/28/04 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2004-08/txt/msg00459.txt.bz2 Okay, here's a patch for unload.exp to make it work on hpux 11.11. I tested it on hpux 11.11 with both hp ansi c B.11.11.28706.GP and gcc 3.3.4. I didn't test it on any linux. It will be easy to add more arms to the "switch" statement as it gets tested on more operating systems. Can you: throw this chunk in rip out the old bug-gdb address rip out the "-L" / "-rpath" leftovers (see below) re-test on i686-pc-linux-gnu re-post the patch (mention that you re-tested on i686-pc-linux-gnu) Right before gdb_exit there is a chunk of code to set "-L" or "-rpath". It looks dead because these values are never used after being set. Can you rip that out? Sorry I didn't catch that earlier. Then I will re-test on native hppa2.0w-hp-hpux11.11 and that ought to be good for approval. Michael C --- /house/chastain/u/unload.exp 2004-08-12 07:32:11.268088000 -0400 +++ unload.exp 2004-08-12 09:09:43.989638000 -0400 @@ -48,7 +48,14 @@ return -1 } -if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DSHLIB_DIR\=\"${shlibdir}\"" "libs=-ldl"]] != "" } { +set dl_lib_flag "" +switch -glob [istarget] { + "hppa*-hp-hpux*" { } + "*-*-linux*" { set dl_lib_flag "libs=-ldl" } + default { } +} + +if { [gdb_compile "${srcdir}/${subdir}/${srcfile}" "${binfile}" executable [list debug "additional_flags=-DSHLIB_DIR\=\"${shlibdir}\"" $dl_lib_flag]] != "" } { gdb_suppress_entire_file "Testcase compile failed, so all tests in this file will automatically fail." }