Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 27 Oct 2004 10:24:56 -0600
From:      Greg Lewis <glewis@eyesbeyond.com>
To:        Lars Tunkrans <lars.tunkrans@bredband.net>
Cc:        marcel@freebsd.org
Subject:   Re: How I got linux emulation to work for AMD64 on RC1
Message-ID:  <20041027162456.GA81485@misty.eyesbeyond.com>
In-Reply-To: <417ECCFE.7010105@bredband.net>
References:  <417ECCFE.7010105@bredband.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, Oct 27, 2004 at 12:17:34AM +0200, Lars Tunkrans wrote:
> This is a step by step guide to get linux emulation to run
> on AMD64 5.3-RC1 using the standard emulators/linux_base port.

Well, it will get you Linux/ia32 emulation, not Linux/amd64 emulation.

[...]

> 5.) Patch  /usr/ports/emulators/linux_base/Makefile with
>     Francois Tigeot's patch.
> 
>     Put the patch below  in /usr/ports/emulators/linux_base/patchfile
>     run:
> 
>     # patch -p0 < patchfile
> 
> ---------------<snip>------------------
> --- Makefile.orig    Wed Oct  6 15:13:33 2004
> +++ Makefile    Wed Oct  6 16:05:51 2004
> @@ -110,6 +110,9 @@
>  RPM=            LC_ALL=C rpm
>  RPMFLAGS=        --root ${LINUXBASE} --dbpath ${DBPATH} --nodeps \
>              --replacepkgs --ignoreos --ignorearch
> +.if (${ARCH} == "amd64")
> +RPMFLAGS+=    --noscripts
> +.endif

This explains why you need to run ldconfig later on.  Essentially, judging
from this and the brandelf lines in the ldconfig step the kernel doesn't
automatically recognise the executables as Linux executables.  Is that the
only reason for turning scripts off or are there bigger problems with the
pre/post install scripts?

This is a hack at best and potentially results in the port not quite being
configured correctly, depending on what the scripts actually do (most do
little, from memory, although quite a few run ldconfig, so this may be ok).
A more complete fix would either have the executables recognised as Linux
executables automatically (and remove the --noscripts flag) or execute
all the scripts in the post-install phase of the port after the brandelf
operations.

FWIW.

-- 
Greg Lewis                          Email   : glewis@eyesbeyond.com
Eyes Beyond                         Web     : http://www.eyesbeyond.com
Information Technology              FreeBSD : glewis@FreeBSD.org



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20041027162456.GA81485>