There are still some issues on Windows, especially with Dual Shock controllers, but a larger rewrite is required anyway of the input handling so it's not worthwhile trying to fix it at this time.
This resolves an irritating issue in the code editor where SDL2-specific functions could't be found. Not entirely sure about the SDL include file logic for other operating systems than Linux so the #ifdef directives may need to be updated further at a later date.
Also a general cleanup of CMakeLists.txt and many small code changes to satisfy Clang that complained quite a lot and actually wouldn't compile the binary at all at first.
As pugixml seems to be well supported nowadays and seems to ship with most distributions it's pretty pointless to keep bundling it with EmulationStation.