Compilation fixes for STP