]> git.ipfire.org Git - thirdparty/libvirt.git/commit
python: always include config.h first
authorEric Blake <eblake@redhat.com>
Tue, 20 Mar 2012 22:44:39 +0000 (16:44 -0600)
committerEric Blake <eblake@redhat.com>
Tue, 20 Mar 2012 22:54:39 +0000 (16:54 -0600)
commit2791b8ab9b7027433ba34946de8a43de8231b722
tree5fbc7b98c200c5aa1b4c304f197e4b1385a3d7d2
parente22789de17fad112f0746366fd13d2d04f742ccf
python: always include config.h first

On RHEL 5.7, I got this compilation failure:

In file included from /usr/include/python2.4/pyport.h:98,
                 from /usr/include/python2.4/Python.h:55,
                 from libvirt.c:3:
../gnulib/lib/time.h:468: error: expected ';', ',' or ')' before '__timer'

Turns out that our '#define restrict __restrict' from config.h wasn't
being picked up.  Gnulib _requires_ that all .c files include <config.h>
first, otherwise the gnulib header overrides tend to misbehave.

Problem introduced by patch c700613b8.

* python/generator.py (buildStubs): Include <config.h> first.
python/generator.py