fix compile errors on Android