test/Makefile: only look at $(KERNELDIR)/usr/include for files with quotes
authorDaniel Mack <zonque@gmail.com>
Tue, 19 Aug 2014 13:19:40 +0000 (15:19 +0200)
committerDaniel Mack <zonque@gmail.com>
Tue, 19 Aug 2014 13:19:40 +0000 (15:19 +0200)
This is a hack to make cpp look at system include files first, and then
consult $(KERNELDIR)/usr/include. For this to work, include directives
referring to files in uapi have to be addressed with quotes.

test/Makefile
test/kdbus-util.c

index 38459a275fed021c00b988522e0709441edd4c3e..a0a1edb1fb932d5660d874760f9d71b8c6aeecaf 100644 (file)
@@ -1,6 +1,7 @@
 CFLAGS         += -std=gnu99 -Wall -Wextra -g \
-                  -I$(KERNELDIR)/usr/include \
                   -I$(KERNELDIR)/include/uapi \
+                  -I. \
+                  -I- \
                   -D_GNU_SOURCE \
                   -Wno-unused-parameter \
                   -Wmaybe-uninitialized \
index f79d7ecf680b24a36cb97532cd269fd11a13185b..67b7435c7c17eace5620ee287f3ff1c2be82f1c1 100644 (file)
 #include <sys/ioctl.h>
 #include <sys/mman.h>
 #include <sys/stat.h>
-#include <linux/memfd.h>
 #include <linux/unistd.h>
 #include <linux/fcntl.h>
 
+#include "linux/memfd.h"
 #include "kdbus-util.h"
 #include "kdbus-enum.h"