Eliminate many compiler warnings from gcc