Snapping application that depends on glibc-2.34

I’m building an application that uses a custom patched version of Qt 5.15. Ubuntu 21.10 will come with that Qt 5.15, so building this Qt version was the easiest on that version. Consequently, this Qt build and my application depends on glibc-2.34, which is newer than the one in the core20 base (2.31). There is no core21 and I assume there won’t be, since it’s not an LTS release. What can I do to snap this application with a core20 base?

I’m just starting with Snap, so could possibly be mistaken, but I don’t think there is a way around this, it seems you have to build your application/Qt 5.15 on a 20.04 system, your binary will be linked against the glibc that was used at build time and that library has to come the corresponding version that the base snap is from, which in your case 20.04 to make it compatible with core20. I don’t think you can only upgrade glibc version on top of base, that’s going to cause other issues.

This is exactly what I ended up doing.