I believe Ubuntu 18.04 should work, since the ELF project 18 uses it.
I guess you’re not setting some build flag correctly, see #675 21 or #1696 13, if those do not help you, search around the  issues section on github, I bet someone has faced (and solved) a similar problem.