fixed some warnings, improved options