Fix installation problems and improve in-code docs.