more compile fixes for sangam-atm and 2.6.31