From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 24206 invoked by alias); 22 Apr 2002 10:55: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 24199 invoked from network); 22 Apr 2002 10:55:06 -0000 Received: from unknown (HELO fw-cam.cambridge.arm.com) (193.131.176.3) by sources.redhat.com with SMTP; 22 Apr 2002 10:55:06 -0000 Received: by fw-cam.cambridge.arm.com; id LAA03327; Mon, 22 Apr 2002 11:55:05 +0100 (BST) Received: from unknown(172.16.1.2) by fw-cam.cambridge.arm.com via smap (V5.5) id xma003239; Mon, 22 Apr 02 11:54:58 +0100 Received: from cam-mail2.cambridge.arm.com (localhost [127.0.0.1]) by cam-admin0.cambridge.arm.com (8.9.3/8.9.3) with ESMTP id LAA07073; Mon, 22 Apr 2002 11:54:57 +0100 (BST) Received: from sun18.cambridge.arm.com (sun18.cambridge.arm.com [172.16.2.18]) by cam-mail2.cambridge.arm.com (8.9.3/8.9.3) with ESMTP id LAA05229; Mon, 22 Apr 2002 11:54:57 +0100 (BST) Message-Id: <200204221054.LAA05229@cam-mail2.cambridge.arm.com> To: "David S. Miller" cc: ac131313@cygnus.com, msnyder@redhat.com, gdb-patches@sources.redhat.com, Richard.Earnshaw@arm.com Reply-To: Richard.Earnshaw@arm.com Organization: ARM Ltd. X-Telephone: +44 1223 400569 (direct+voicemail), +44 1223 400400 (switchbd) X-Fax: +44 1223 400410 X-Address: ARM Ltd., 110 Fulbourn Road, Cherry Hinton, Cambridge CB1 9NJ. X-Url: http://www.arm.com/ Subject: Re: [RFA] Sparc/Linux fixes part 1 In-reply-to: Your message of "Fri, 19 Apr 2002 19:44:17 PDT." <20020419.194417.101826241.davem@redhat.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 22 Apr 2002 03:55:00 -0000 From: Richard Earnshaw X-SW-Source: 2002-04/txt/msg00783.txt.bz2 > From: Andrew Cagney > Date: Fri, 19 Apr 2002 22:46:23 -0400 > > How does this Kernel, for instance, differentate between a GNU/Linux > sparc binary and a Solaris binary when doing emulation? > > I'm going to delete the Solaris binary support any day now as an > aside. > > The two binaries look identical, the both look like elf32_sparc. > I don't know how many times I can say this. > > "The binaries look identical, but we screwed up on Sparc/Linux > a long time ago and the long double type is 8 bytes instead of > the ABI mandated 16 bytes. We are in no position to change this > with the amount of existing binaries out there." > > There is no distinguising characterstic in the elf header nor anywhere > else. I'm sticking my nose in here where I probably don't know all the facts, so please excuse me if I'm barking up the wrong tree... glibc does provide a note in the executable, which as I understand it, will differ between Linux and Solaris. Can you not assume that if the note is missing entirely that you have a Sun/Solaris system and that if it is present you can use it to determine the OS and hence the ABI? See glibc/abi-tags and glibc/csu/abi-note.S R.