remove os-dependent code