Build and optimization

Hi man, I've just fixed build issue and changed non-optimize code. I think it will be great ro merge my changes with your code.
You can nontact me in anytime: edward.sarkisyan@gmail.com