Fix a bunch of linux build errors.