lib: add weak clz/ctz functions

https://github.com/poondog/kangaroo-m7-mkv/commit/46ba551d7489a438923b28ee974d62681b6c0b1f