fix build for OSS code (take 2)