Use installed kernel headers instead of in-tree headers
authorLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Tue, 21 Dec 2010 11:47:38 +0000 (12:47 +0100)
committerLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Tue, 21 Dec 2010 11:47:38 +0000 (12:47 +0100)
To install kernel headers to usr/include inside a kernel tree, just run
make headers_install. media-ctl can then be compiled by setting KDIR to
the patch to the kernel tree.

Signed-off-by: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Makefile

index b1e6bfc..a89b79c 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -1,8 +1,7 @@
-SRCARCH ?= arm
-CROSS_COMPILE ?= arm-none-linux-gnueabi-
-KDIR ?= /usr/src/linux
+CROSS_COMPILE ?=
+KDIR ?=
 
 
-KINC := -I$(KDIR)/include -I$(KDIR)/arch/$(SRCARCH)/include
+KINC := -I$(KDIR)/usr/include
 CC   := $(CROSS_COMPILE)gcc
 
 CFLAGS += -O2 -Wall -fpic -I. $(KINC)
 CC   := $(CROSS_COMPILE)gcc
 
 CFLAGS += -O2 -Wall -fpic -I. $(KINC)