libretro: only use posix_memalign when it's safe