From owner-freebsd-questions@FreeBSD.ORG Thu Aug 7 19:07:04 2008 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id A2CCC106568C for ; Thu, 7 Aug 2008 19:07:04 +0000 (UTC) (envelope-from kris@FreeBSD.org) Received: from weak.local (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id B49D28FC13; Thu, 7 Aug 2008 19:07:03 +0000 (UTC) (envelope-from kris@FreeBSD.org) Message-ID: <489B47D5.9070901@FreeBSD.org> Date: Thu, 07 Aug 2008 21:07:01 +0200 From: Kris Kennaway User-Agent: Thunderbird 2.0.0.16 (Macintosh/20080707) MIME-Version: 1.0 To: Maxim Khitrov References: <26ddd1750808071055i2b9976b3i4f347407d94a0813@mail.gmail.com> <489B3909.6080702@FreeBSD.org> <26ddd1750808071107r311c8f16hdb2982bab7291ac2@mail.gmail.com> In-Reply-To: <26ddd1750808071107r311c8f16hdb2982bab7291ac2@mail.gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Cc: FreeBSD Questions Subject: Re: Linking amd64 binary with a 32-bit linux library X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 07 Aug 2008 19:07:04 -0000 Maxim Khitrov wrote: > On Thu, Aug 7, 2008 at 2:03 PM, Kris Kennaway wrote: >> Maxim Khitrov wrote: >> >>> I take it that this happens because libmat.so is a linux binary, but >>> is there any way to do what I'm after? >> You can't mix and match Linux and FreeBSD code in the same binary. You will >> have to make a completely Linux binary, either by compiling on a Linux >> system, or by installing a Linux toolchain into a chroot and building there. >> >> Kris >> > > I thought so. In that case, if I need to have this library loaded by > mod_ruby, and mod_ruby loaded by apache, I take it that I will have to > recompile all of these as linux binaries if I want to interface with > matlab? I guess I should have thought about this first. :-\ If you have to run them all in the same process, then yes. Depending on what you are trying to achieve you may be able to use another form of IPC to interface them (e.g. socket, shared memory, etc). Kris