Add quirks for libmgba-dev
Some of these are workarounds for bugs in the package which should be fixed, but for now this MR should serve to unblock the analysis.
-
patches/libmgba-dev.patch: Fix mismatchedCXX_GUARD_STARTin.../renderers/video-software.h. Will report upstream. -
mgba-util/png-io.hdoes#undefine restrict, so it cannot be processed in the same run as any headers that userestrict. Worked around using a virtual package to processpng-io.hseparately from the other headers. - Added
libpng-devand definedUSE_PNGforpng-io.h. - Added
mgba-util/common.htopreambleas it should be included before any other headers. - Defined
HAVE_LOCALEto avoid a conflicting redefinition oflocale_t. - Skipped foreign platform headers under
platform/*/*.h. These are included conditionally by platform detection macros in (for example)mgba-util/threading.hand are not meant to be included directly. Will consider fixing libmgba-dev to exclude those headers that are unusable on Debian, but they should be harmless.