libnative: generic retry() for 64 bit read/write().

The current implementation of `retry()` cannot handle, say, `write()` of >2 GB data because it truncates the return value of the closure parameter into `c_int` which is (almost always) only 32 bit.

This is my first code to use traits... I hope `#[inline]` works as intended.

I think `mkerr_libc()` is still causing bugs here and there;  I'll fix them later.