import from https://code.google.com/p/project-hos