lib: Fix x/lib for go1.6

There are 2 changes in go1.6 that affect x/lib.

The signal package was changed wrt writing to broken pipes.
Basically we'll get a SIGPIPE when writing to a broken os.Stdout.
The fix is to detect the SIGPIPE-based failure, and handle it
appropriately in IgnoreClosedPipeError mode.

The utf8.FullRune function was also re-implemented to be faster.
As a side-effect, this also fixed some bugs with the original
implementation.  The bug causes differing behavior under go1.5 vs
go1.6, but thankfully only affects a particular test case, which
isn't actually that important.  The fix is to comment-out the
test case, which is updated to work for go1.6.  Once we've
switched over, we'll uncomment the test case.

https://go-review.googlesource.com/#/c/16940/4/src/unicode/utf8/utf8.go@a142

Issue https://v.io/i/1165

Change-Id: Id7095ac112e465ea1eeb7823fb2b693116bab290
2 files changed