Musl fixes v3

this is an updated patch following up to https://github.com/zfsonlinux/zfs/pull/2604
this patch is lacking the libtirpc modifications due to licensing issues a patch for alpine linux containing also libtirpc support is maintained at https://github.com/stef/aports/blob/master/testing/zfs-grsec/musl-fixes.patch.