Disco
Disco

Reputation: 4386

How to run wine inside a chrooted environment in ubuntu?

I'm trying to run wine inside a 'pseudo' jail inside Ubuntu.

I've been able to debootstrap an Ubuntu install and run wine inside it so far.

Problem is that there are a LOT of libraries that are being included.

Is there a simple way to figure out which libraries are required by wine ?

I've tried ldd /usr/bin/wine

linux-gate.so.1 =>  (0xf7702000)
libwine.so.1 => /usr/bin/../lib32/libwine.so.1 (0xf75bf000)
libpthread.so.0 => /lib32/libpthread.so.0 (0xf7590000)
libc.so.6 => /lib32/libc.so.6 (0xf7433000)
libdl.so.2 => /lib32/libdl.so.2 (0xf742f000)
/lib/ld-linux.so.2 (0xf7703000)

But that doesn't help me much to figure out which libraries are actually needed.

EDIT: i'm running wine from Xvnc (.vnc/xstartup):

env DISPLAY=127.0.0.1$DISPLAY CHROOT_DIR=/home/chroot \
COMMAND="/usr/bin/wine $HOME/myapp.exe"

Where '/home/chroot' is the debootstrapped install.

Is there a better way?

Upvotes: 0

Views: 5240

Answers (1)

Martijn
Martijn

Reputation: 1620

There is, and it's called schroot. It helps you set up and maintain chroot environments.

Another option would be to manually run debootstrap on your prospective chroot, so you have apt and dpkg available inside it (so you can just run apt-get install wine while you're in the chroot).

More information on both options is available on the Ubuntu Wiki

Upvotes: 1

Related Questions