scanner: Reverse expat/libxml include order
authorDaniel Stone <daniels@collabora.com>
Tue, 28 Aug 2018 22:59:35 +0000 (23:59 +0100)
committerDaniel Stone <daniels@collabora.com>
Wed, 29 Aug 2018 08:58:49 +0000 (09:58 +0100)
commit4939923d3a8487f6644b1feb657693d8f929297b
treefe8ece071dae90ecfc8db80541d3ad445202b22d
parent5fab243a729c949d38463c47040ea6abec8d7850
scanner: Reverse expat/libxml include order

libxml2 unconditonally defines XMLCALL to nothing. Expat does not
redefine XMLCALL if it is already defined, but if it is not, and we are
building with gcc on i386 (not x86-64), it will define it as 'cdecl'.

Including Expat before libxml thus results in a warning about XMLCALL
being redefined. Luckily we can get around this by just reversing the
include order: cdecl is a no-op on Unix-like systems, so by having
libxml first define XMLCALL to nothing and including Expat afterwards,
we avoid the warning and lose nothing.

Signed-off-by: Daniel Stone <daniels@collabora.com>
Reviewed-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
src/scanner.c