Fixed logging bug and added lite support.