Fixes for installation
Various fixes for bugs