diff --git a/tools/ports/sdl2.py b/tools/ports/sdl2.py index b8fba24bc2cc4..b9d26d398cb37 100644 --- a/tools/ports/sdl2.py +++ b/tools/ports/sdl2.py @@ -70,7 +70,8 @@ def create(final): srcs += ['thread/%s/%s' % (thread_backend, s) for s in thread_srcs] srcs = [os.path.join(src_dir, 'src', s) for s in srcs] - flags = ['-sUSE_SDL=0'] + # TODO: Remove fwrapv when we update to a version which includes https://github.com/libsdl-org/SDL/pull/12581 + flags = ['-sUSE_SDL=0', '-fwrapv-pointer'] includes = [ports.get_include_dir('SDL2')] if settings.PTHREADS: flags += ['-pthread']