We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 4392

Summary: SDL_cpuinfo.h breaks compilation with C bool type
Product: SDL Reporter: Luke Dashjr <luke-jr+sdlbugs>
Component: *don't know*Assignee: Sam Lantinga <slouken>
Status: RESOLVED FIXED QA Contact: Sam Lantinga <slouken>
Severity: major    
Priority: P2    
Version: HG 2.0   
Hardware: PowerPC   
OS: Linux   

Description Luke Dashjr 2018-11-20 03:35:11 UTC
Bug 3993 was "fixed" by #undef'ing bool. But this breaks C99's stdbool.h bool too.

For example, mpv's build fails with:

../audio/out/ao_sdl.c:35:5: error: unknown type name ‘bool’

It seems ill-advised to be #undef'ing *anything* here - what if the code including SDL_cpuinfo.h actually wants to use altivec?

I also don't understand why altivec.h is included in this header at all. It doesn't seem to use it?
Comment 1 Sam Lantinga 2018-11-20 05:29:17 UTC
Good points. This is fixed, thanks!
https://hg.libsdl.org/SDL/rev/6da95eef84a2