Musl support for zfsonlinux

These patches introduce compatibility with musl as libc.

Please review and advise what to tweak to make it eligible for merging. I understand that some of the changes could be done better, however i lack the necessary familiarity with this fine source code and its customs.