Although I still can't build ELPA (see Bug#31118#31), I took a shot at making ELPA build for 32-bit Emacs on master by installing the attached patches into the xelb and exwm packages, respectively. As I understand it, some parts of ELPA still assume 64-bit Emacs, but that's lower priority as it's not a regression. Also, one still cannot reliably build ELPA on 64-bit Emacs and run it on 32-bit Emacs (or vice versa), but people don't do that much and I suspect it wasn't really working either.