iapbs compilation fixes