From owner-freebsd-emulation@FreeBSD.ORG Fri Aug 27 09:20:26 2004 Return-Path: Delivered-To: freebsd-emulation@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id B06AC16A4CF; Fri, 27 Aug 2004 09:20:26 +0000 (GMT) Received: from mail836.megamailservers.com (mail836.carrierinternetsolutions.com [69.49.106.46]) by mx1.FreeBSD.org (Postfix) with ESMTP id 55AA143D48; Fri, 27 Aug 2004 09:20:26 +0000 (GMT) (envelope-from strick@covad.net) X-POP-User: scorpiogirl.covad.net Received: from mist.nodomain (h-68-164-175-152.snfccasy.dynamic.covad.net [68.164.175.152])i7R9KOHX007464; Fri, 27 Aug 2004 05:20:25 -0400 Received: from mist.nodomain (localhost [127.0.0.1]) by mist.nodomain (8.12.11/8.12.11) with ESMTP id i7R9KOsN000621; Fri, 27 Aug 2004 02:20:24 -0700 (PDT) (envelope-from dan@mist.nodomain) Received: (from dan@localhost) by mist.nodomain (8.12.11/8.12.11/Submit) id i7R9KNvr000620; Fri, 27 Aug 2004 02:20:23 -0700 (PDT) (envelope-from dan) Date: Fri, 27 Aug 2004 02:20:23 -0700 (PDT) From: Dan Strick Message-Id: <200408270920.i7R9KNvr000620@mist.nodomain> To: emulation@FreeBSD.org, freebsd-bugs@FreeBSD.org, linimon@FreeBSD.org Subject: Re: kern/46576: FreeBSD 4.6 broke linux emulation install w/SVR4 emulation enabled. X-BeenThere: freebsd-emulation@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Development of Emulators of other operating systems List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Aug 2004 09:20:26 -0000 > > Synopsis: FreeBSD 4.6 broke linux emulation install w/SVR4 emulation enabled. > > ... > > http://www.freebsd.org/cgi/query-pr.cgi?pr=46576 > I believe I also submitted a PR on this one a while back. The cause of the problem seems to be that Linux (or at least the Redhat Linux executable binaries used by most of the Linux emulation ports) uses the ELF OS ABI code assigned for SYSV (which happens to be zero) and not the code assigned for LINUX. Perhaps Linux ELF executables are simply not branded by default. (See the symbols ELFOSABI* defined in /usr/include/sys/elf_common.h.) I won't speculate as to whose "fault" this is. The upshot is that if you have enabled both the SVR4 and LINUX emulators, FreeBSD may choose the wrong emulator some of the time. I vaguely recall that there is a sysctl variable that can establish a default brand other than zero. I don't see how this can help if you have both Linux and SVR4 binaries on your system. Since I didn't actually have any SVR4 binaries to run at the time, my workaround was simply to disable the SVR4 emulator. I think I recently read in one of the FreeBSD mailing lists that SVR4 emulation is scheduled for the scrap heap since nobody seems to be using it. Perhaps this is one reason why. Perhaps the Linux emulator ports should rebrand all Linux ELF files before installing them. Dan Strick strick@covad.net