Page 1 of 1

case SDL_KEYMAPCHANGED

Posted: 23 Feb 2018, 07:46
by nif
Trying to compile from latest head (9b8c56761b5c9b398aebb91fec6adf25208c24d9) I get this error after running make:

Code: Select all

[ 21%] Building CXX object components/CMakeFiles/components.dir/sdlutil/sdlcursormanager.cpp.o
/home/derrick/games/OpenMW/openmw/components/sdlutil/sdlinputwrapper.cpp: In member function ‘void SDLUtil::InputWrapper::capture(bool)’:
/home/derrick/games/OpenMW/openmw/components/sdlutil/sdlinputwrapper.cpp:113:22: error: ‘SDL_KEYMAPCHANGED’ was not declared in this scope
                 case SDL_KEYMAPCHANGED:
                      ^
[ 21%] Building CXX object components/CMakeFiles/components.dir/version/version.cpp.o
[ 21%] Building CXX object components/CMakeFiles/components.dir/fallback/fallback.cpp.o
make[2]: *** [components/CMakeFiles/components.dir/sdlutil/sdlinputwrapper.cpp.o] Error 1
make[2]: *** Waiting for unfinished jobs....
make[1]: *** [components/CMakeFiles/components.dir/all] Error 2
make: *** [all] Error 2
Ubuntu 14.04

Re: case SDL_KEYMAPCHANGED

Posted: 23 Feb 2018, 08:46
by akortunov
SDL_KEYMAPCHANGED was added in SDL 2.0.4, so you can try to use it or later versions. Google says Trusty uses the 2.0.2.

The only place which uses this event is here.
But anyway this behaviour is strange since this code should be omitted by preprocessor if you have the old SDL.
Maybe a some kind of false-detection involved.

Re: case SDL_KEYMAPCHANGED

Posted: 24 Feb 2018, 08:15
by nif
Thanks, I was able to compile after installing SDL 2.0.7