Commit ed340abc authored by Emil Velikov's avatar Emil Velikov Committed by Alan Coopersmith
Browse files

Include config.h before any other headers.



The former has a series of defines which in some cases are crusial to be
set before including any system headers.
Signed-off-by: Emil Velikov's avatarEmil Velikov <emil.l.velikov@gmail.com>
Reviewed-by: Alan Coopersmith's avatarAlan Coopersmith <alan.coopersmith@oracle.com>
Signed-off-by: Alan Coopersmith's avatarAlan Coopersmith <alan.coopersmith@oracle.com>
parent 6329ef9e
......@@ -25,6 +25,10 @@
*
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <stdio.h>
#include <string.h>
#include <unistd.h>
......@@ -33,10 +37,6 @@
#include <stdlib.h>
#include <limits.h>
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "pciaccess.h"
#include "pciaccess_private.h"
......
......@@ -33,6 +33,10 @@
* \author Eric Anholt <eric@anholt.net>
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
......@@ -45,10 +49,6 @@
#include <sys/mman.h>
#include <sys/memrange.h>
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include "pciaccess.h"
#include "pciaccess_private.h"
......
......@@ -34,6 +34,10 @@
#define _GNU_SOURCE
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
......@@ -57,10 +61,6 @@
#define iopl(x) -1
#endif
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#ifdef HAVE_MTRR
#include <asm/mtrr.h>
#include <sys/ioctl.h>
......
......@@ -16,15 +16,15 @@
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
*/
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#include <sys/param.h>
#include <sys/ioctl.h>
#include <sys/mman.h>
#include <sys/types.h>
#ifdef HAVE_CONFIG_H
#include "config.h"
#endif
#ifdef HAVE_MTRR
#include <machine/sysarch.h>
#include <machine/mtrr.h>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment