public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: risingpower@gmx.de
To: cygwin@cygwin.com
Subject: SDL2: Gamepads stopped working
Date: Tue, 3 Oct 2023 11:20:30 +0200	[thread overview]
Message-ID: <trinity-afffb928-7dcc-4324-9a33-bc0df9a7f294-1696324830677@3c-app-gmx-bap13> (raw)

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;
}


             reply	other threads:[~2023-10-03  9:20 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-10-03  9:20 risingpower [this message]
2023-10-03 12:26 ` Takashi Yano
2023-10-03 12:32 risingpower
2023-10-05 13:07 risingpower
2023-10-05 14:12 ` Takashi Yano
2023-10-05 15:15 risingpower
2023-10-05 16:38 ` Takashi Yano
2023-10-06  7:26 risingpower
2023-10-06 11:14 ` Takashi Yano
2023-10-06 12:00   ` risingpower
2023-10-08 15:07     ` Takashi Yano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=trinity-afffb928-7dcc-4324-9a33-bc0df9a7f294-1696324830677@3c-app-gmx-bap13 \
    --to=risingpower@gmx.de \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).