How to build Gnucash in /home/<user>/opt?

Hi, your best bet would be to use a Podman container to run Ubuntu within EOS and GNUcash inside it. See Running Ubuntu with Podman