Make kernel source path configurable
PATCH 1/1 Make kernel source path configurable
Add an optional argument to the user-cs Makefile called KERNELPATH that allows one to specify the path for kernel sources to use for the build.
Signed-off-by Mike Waychison <[email protected]>
---
Makefile | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-)
Makefile +4 -4
@@ -1,13 +1,13 @@ - +KERNELPATH ?= ../linux # compile with debug ? DEBUG = -DCHECKPOINT_DEBUG # find linux architecure -KERN_ARCH = $(shell readlink ../linux/include/asm | sed 's/^asm-//') +KERN_ARCH = $(shell readlink $(KERNELPATH)/include/asm | sed 's/^asm-//') # look for includes -PATHS = -I../linux/include \ - -I../linux/arch/$(KERN_ARCH)/include +PATHS = -I$(KERNELPATH)/include \ + -I$(KERNELPATH)/arch/$(KERN_ARCH)/include # extra warnings and fun WARNS := -Wall -Wstrict-prototypes -Wno-trigraphs
A message that is not in the archive (sent off-list or not yet received): 20090129021528.22655.32316.stgit-KRTu2lV406v8o+N1Ual6GVaTQe2KTcn/@public.gmane.org
Thanks.
Quoted 33 lines · Mike Waychison
Add an optional argument to the user-cs
Makefilecalled KERNELPATH that allows one to specify the path for kernel sources to use for the build.Signed-off-by Mike Waychison <[email protected]>---
Makefile | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-)Makefile +4
-4@@ -1,13 +1,13 @@ - +KERNELPATH ?= ../linux # compile with debug ? DEBUG = -DCHECKPOINT_DEBUG # find linux architecure -KERN_ARCH = $(shell readlink ../linux/include/asm | sed 's/^asm-//') +KERN_ARCH = $(shell readlink $(KERNELPATH)/include/asm | sed 's/^asm-//') # look for includes -PATHS = -I../linux/include \ - -I../linux/arch/$(KERN_ARCH)/include +PATHS = -I$(KERNELPATH)/include \ + -I$(KERNELPATH)/arch/$(KERN_ARCH)/include # extra warnings and fun WARNS := -Wall -Wstrict-prototypes -Wno-trigraphs