The Debian way
When you suffice with the Debian wine version, you just do apt install wine
and you're done. If your application doesn't need it, there is no need to install the whole 32-bit system. Beware, application often does.
My Debian CI image is based on stable and we need new WINE...
Then you have to go for Debian WINEHQ repository.
...but I don't want the 32-bit environment...
Probably (?) for good reason (avoiding users' issues due to missing i386 environment, which many amd64 application components do use), WINE developers decided to force you to install 32-bit libraries. This in fact means, you have to install 32-bit multiarch.
We don't want to do that in our CI, which will run one 64-bit application (Apitrace).
In this example, I'll use wine-stable
.
We want to do the basic steps:
apt-key add /winehq.gpg.key
apt-add-repository https://dl.winehq.org/wine-builds/debian/
apt-get -y install --no-install-recommends wine-stable-amd64
and then continue with hacks to get debian the package right.
apt download wine-stable
dpkg --ignore-depends=wine-stable-i386 -i wine-stable*.deb
rm wine-stable*.deb
sed -i "/wine-stable-i386/d" /var/lib/dpkg/status
voila! It's not nice, but it does work.