modified slightly for usage in Mednafen

ARM stuff not compiled in, for now.
