build: fixes for mingw-w64

R=rsc
CC=golang-dev
https://golang.org/cl/4742042
3 files changed