fix various installation problems