Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SDL_syswm.h with SDL_PROTOTYPES_ONLY broken in C++ mode #3055

Closed
SDLBugzilla opened this issue Feb 11, 2021 · 0 comments
Closed

SDL_syswm.h with SDL_PROTOTYPES_ONLY broken in C++ mode #3055

SDLBugzilla opened this issue Feb 11, 2021 · 0 comments

Comments

@SDLBugzilla
Copy link
Collaborator

SDLBugzilla commented Feb 11, 2021

This bug report was migrated from our old Bugzilla tracker.

Reported in version: 2.0.9
Reported for operating system, platform: Linux, x86_64

Comments on the original bug report:

On 2018-11-06 17:27:24 +0000, Daniel Scharrer wrote:

$ cat test.cpp
#include <SDL.h>
#define SDL_PROTOTYPES_ONLY 1
#include <SDL_syswm.h>

int main() { }

$ g++ $(pkg-config sdl2 --cflags --libs) test.cpp
In file included from test.cpp:3:
/usr/include/SDL2/SDL_syswm.h:318:1: error: expected declaration before ‘}’ token
}
^

On 2018-11-06 17:51:05 +0000, Ozkan Sezer wrote:

Should be fixed by https://hg.libsdl.org/SDL/rev/244cdac21bcd
Thanks.

On 2018-11-06 19:06:27 +0000, Ozkan Sezer wrote:

BTW, this was broken in C-only mode too when SDL_PROTOTYPES_ONLY
was defined, because it included close_code.h without including
begin_code.h first, possibly messing with structure packings..

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant