Build fixes for gcc.