From owner-freebsd-amd64@FreeBSD.ORG Thu Nov 25 20:42:35 2004 Return-Path: Delivered-To: freebsd-amd64@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 72FC416A4CE for ; Thu, 25 Nov 2004 20:42:35 +0000 (GMT) Received: from canning.wemm.org (canning.wemm.org [192.203.228.65]) by mx1.FreeBSD.org (Postfix) with ESMTP id 5140243D45 for ; Thu, 25 Nov 2004 20:42:35 +0000 (GMT) (envelope-from peter@wemm.org) Received: from fw.wemm.org (canning.wemm.org [192.203.228.65]) by canning.wemm.org (Postfix) with ESMTP id 28B9D2A8D5 for ; Thu, 25 Nov 2004 12:42:35 -0800 (PST) (envelope-from peter@wemm.org) Received: from overcee.wemm.org (overcee.wemm.org [10.0.0.3]) by fw.wemm.org (Postfix) with ESMTP id 87121E2B3 for ; Thu, 25 Nov 2004 12:42:34 -0800 (PST) (envelope-from peter@wemm.org) Received: from overcee.wemm.org (localhost [127.0.0.1]) by overcee.wemm.org (8.13.1/8.13.1) with ESMTP id iAPKgX5s003666; Thu, 25 Nov 2004 12:42:33 -0800 (PST) (envelope-from peter@wemm.org) Received: from localhost (localhost [[UNIX: localhost]]) by overcee.wemm.org (8.13.1/8.13.1/Submit) id iAPKgXa4003665; Thu, 25 Nov 2004 12:42:33 -0800 (PST) (envelope-from peter@wemm.org) X-Authentication-Warning: overcee.wemm.org: peter set sender to peter@wemm.org using -f From: Peter Wemm To: freebsd-amd64@freebsd.org Date: Thu, 25 Nov 2004 12:42:33 -0800 User-Agent: KMail/1.7 References: <20041116052630.GD49800@manor.msen.com> <20041124070652.GT49800@manor.msen.com> <80EAD071-3E8F-11D9-AF21-000D93AD5C52@hydrix.com> In-Reply-To: <80EAD071-3E8F-11D9-AF21-000D93AD5C52@hydrix.com> MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200411251242.33406.peter@wemm.org> Subject: Re: How to use older libs in 32bit mode? X-BeenThere: freebsd-amd64@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Porting FreeBSD to the AMD64 platform List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 25 Nov 2004 20:42:35 -0000 On Wednesday 24 November 2004 07:10 pm, Jean-Yves Avenard wrote: > On 24/11/2004, at 6:06 PM, Michael R. Wayne wrote: > > Sorry. No success as in it cores. > > Exact same thing here. Any attempts to run a 32 bits executable on an > AMD64 machines result in a coredump > > Jean-Yves Things to check: * Make sure you have COMPAT_IA32 in your kernel config. For example, this command should work: peter@overcee[8:16pm]~/fbp4/hammer/sys/amd64/conf-120> sysctl kern.elf32 kern.elf32.fallback_brand: -1 (The important thing is that it prints something, not the value) * Make sure you have NOT copied ld-elf or libc from an i386 system. You *MUST* build at least these two on your machine. How to check: peter@overcee[8:17pm]~-123> strings /libexec/ld-elf32.so.1 | grep libmap32 /etc/libmap32.conf If this comes up empty, you're in trouble. Check that /usr/libexec/ld-elf32.so.1 and /libexec/ld-elf.so.1 are the same file. If you are running 5.3-stable and not 5.3-release, you can check libc like this: peter@overcee[8:18pm]~-125> objdump --dynamic-syms /usr/lib32/libc.so.5 | grep fsbase 00026500 g DF .text 0000002b _amd64_set_fsbase 00026580 g DF .text 0000004a _amd64_get_fsbase These will not be present on a 5.3-release system. Oh wait a second. Did you build your libraries with WITH_LIB32=yes or by running build32.sh ? I have a suspicion that build32.sh will produce a bad library now. BTW: it is helpful to do a ktrace/kdump and show the last few lines. I suspect there will be a sysarch syscall, followed by a SIGSEGV. -- Peter Wemm - peter@wemm.org; peter@FreeBSD.org; peter@yahoo-inc.com "All of this is for nothing if we don't go to the stars" - JMS/B5