Various updates to get it to compile