Some fixes to cmake build system for LizardFS

I've merged your changes with currrent lizardfs master and made "make install" work properly.