On Tue, 3 Oct 2023 11:20:30 +0200 risingpower wrote: > Hi, > > after a cygwin update, SDL2 does not recognize my gamepads any more. > They definitely worked before: > libSDL2_2.0_0-2.0.7-1.tar.xz <- joystick worked fine (2021-10-09) > libSDL2_2.0_0-2.28.3-2.tar.xz <- SDL_NumJoysticks() is 0 (2023-09-30) > > Example: > // $ gcc -o testjoystick testjoystick.cc $(pkg-config --cflags --libs SDL2) > #include <SDL.h> > #include <stdio.h> > > int main(int argc, char *argv[]) { > if (!SDL_WasInit(SDL_INIT_JOYSTICK)) { > int res = SDL_Init(SDL_INIT_JOYSTICK); > if (res < 0) > printf("SDL init joystick failed: %s\n", SDL_GetError()); > } > int num_joysticks = SDL_NumJoysticks(); > printf("SDL_NumJoysticks()=%d\n", num_joysticks); > > return 0; > }
This is because SDL_mmjoystick.c is removed from the source tree of upstream since 2.0.18. Now I am trying to enable SDL_dinputjoystick.c or SDL_xinputjoystick.c instead. Hopefully it will work again in 2.28.4. -- Takashi Yano <takashi.y...@nifty.ne.jp> -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation: https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple