Up to date with mitakuuluu2
Fixes to make the library standalone