Fix build almost completely