Added options & fixed compile warnings