Signed-off-by: Pierre-Alain TORET <pierre-alain.toret@protonmail.com>
I know this is a huge commit, but I can't be bothered to check this in part by part.