major fixes and lib updates