initial import, from revision b149c275d3b5