Jump to content
Read the Funtoo Newsletter: Summer 2023 ×

HOWTO: run 32-bit Windows applications on Funtoo-1.4 (my way)


Recommended Posts

Running 32-bit Win apps requires 32-bit wine. The wine available in 1.4 is 64-bit and will not run 32-bit Win binaries.

The following is a quick writeup on how I did it. There are other ways, possibly better, but this one is mine and I stand by it. ?


I opted to use a chrooted 32-bit environment in which I installed Gentoo and wine. I started by making a ~/gentoo folder and downloading a current 32-bit Gentoo stage3 in it:

	mkdir gentoo
	cd gentoo
	wget <stage3_URL>

You need to be root for the following steps

sudo su
	tar xpf <stage3>
	cp /etc/resolv.conf /home/<username>/gentoo/etc

And then follow the installation steps in the Gentoo manual

mount -t proc none proc
mount --rbind /sys sys
mount --rbind /dev dev
env -i HOME=/root TERM=$TERM /bin/chroot . bash -l
	# export PS1="(chroot) $PS1"
	(chroot)# emerge-webrsync
	(chroot)# emerge --sync
	(chroot)# eselect profile list

and select a desktop profile. For me it was #5, default/linux/x86/17.0/desktop (stable). The desktop profile brings in Xorg which will be needed later for wine anyway.

(chroot)# eselect profile set 5

Edit make.conf to add the correct MAKEOPTS ("-j7" worked for me) then do a world update, and go do something else for a couple of hours.

(chroot)# emerge -avuDN @world

Once done, set up Xserver redirection in chroot so it displays the image on the host.

On the host:

xauth list

will show you the "magic" cookie of your host display. Put it into .Xauthority on the chroot:

sudo xauth extract <path_to_chroot>/root/.Xauthority <hostname>/unix:0

where <hostname> is the name of your host machine (mine is eb1)

(edit) NB when you log out of your host then log back in, the cookie changes so you will have to redo the line above, or X redirection will stop working.


In the chroot, verify that the cookie is set correctly:

(chroot)# xauth list

should show the same as on the host

Also set the DISPLAY variable in chroot:

(host) echo $DISPLAY

should show ":0.0"

(chroot)# export DISPLAY=":0.0"

You can add the above line to /etc/profile in Gentoo so it gets automatically set every time you enter the chroot.

Verify that it works. In chroot run xcalc (you may have to install xcalc first), and it should display on the host.

(chroot)# xcalc

If no errors, emerge wine in the chroot and configure it. You should have a 32-bit wine now, ready to run 32-bit Windows binaries (minus configuring, figuring out missing libs etc - but this is beyond the scope of this writeup)

(chroot)# emerge wine

Final size of the chroot Gentoo on my disk was close to 4.5GB.

Link to comment
Share on other sites

  • 3 months later...

I appreciate the post, but I'd like to ask a question.  It seems to me that with the chroot method, there is going to be no integration or interaction between the "host" and the chroot "guest".  That is, I can't start an application in the chroot by clicking on a Plasma icon, or using 'Open With' in Dolphin.  Or the other direction, having a command in a Windows app open a folder in Dolphin or Konsole, or a URL in Firefox.  Have you found ways to make things like this work with your method?  Thanks.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Create New...