Date: Wed, 28 Jun 2006 16:37:50 -0400 From: Kevin Brunelle <kruptos@mlinux.org> To: freebsd-ports@freebsd.org Subject: Re: getting to /usr but not /compat/usr from a linux app Message-ID: <200606281637.50708.kruptos@mlinux.org> In-Reply-To: <7A131765-AD00-4346-A3D1-771ED181EE16@mac.com> References: <20060628172146.GA55051@iib.unsam.edu.ar> <7A131765-AD00-4346-A3D1-771ED181EE16@mac.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Wednesday 28 June 2006 13:53, Charles Swiger wrote: > On Jun 28, 2006, at 1:21 PM, Fernan Aguero wrote: > > I'm using Linux Firefox, and when asked to choose a helper > > app to open a document I try to navigate to /usr/X11R6/bin > > but I always end up in /compat/linux/usr/X11R6/bin instead > > (though firefox believes it's /usr/X11R6/bin). > > > > I can see why this happens (linux apps should be fooled into > > using their 'compat' usr space), but is there any way of > > escaping from this? > > The Linux app is being run inside of a chroot()ed environment in > order to give the appearance that they are running in a "real Linux > system"; you can't escape a chroot() environment (hopefully), but you > could create hard links or copy files from the FreeBSD /usr/X11R6/bin > to the Linux environment... This is not 'exactly' true. The program is not being run in a chroot environment. Easily demonstrated by the fact that linux programs can access file in user's home directories without any difficulty. There are other ways to show this... but the main thing is distinct paths. The programs default to /compat/linux/whatever if whatever exists in both places. You really just need to specify enough of the path manually that the program sees the file outside of /compat/linux. For example, I had to type the complete path for "/usr/X11R6/bin/acroread" into one program for it to show up. But once the complete path is there, the program doesn't have a problem with it. If you get to a part where the program seem stuck (you know there is a different directory you need to enter but you're in the /C/L tree, and all you have is a place to type the filename... try 'directory/<enter>' and most programs take the hint and move you up. Hope this helps. -kevin
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200606281637.50708.kruptos>