Refactoring std os setenv

Hello!

After talking with @huonw on Irc and trying different thing, I purpose to add a error handling over this wrapper of libc::setenv for catching errors.

I will need some help on the two commit marked as `fixup!`. I am still a newbie to rust. :)
I think this would be better as `fail!("`setenv` failed: {}", e)`.