diff options
author | alanh <alanh> | 2001-04-06 15:49:42 +0000 |
---|---|---|
committer | alanh <alanh> | 2001-04-06 15:49:42 +0000 |
commit | a6e72223ef5cf89c868113ef1ddf65bcc7e981b6 (patch) | |
tree | 7d5454e2eb91d2bdc57620afe6180f84be8684b0 | |
parent | f32be1134b706ae9b41f34dcdfa9c99e01ae7c49 (diff) |
search /lib/modules/<version>/build/include first, then the others....
-rw-r--r-- | xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.linux | 17 |
1 files changed, 12 insertions, 5 deletions
diff --git a/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.linux b/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.linux index 702fca0d7..95044e6f8 100644 --- a/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.linux +++ b/xc/programs/Xserver/hw/xfree86/os-support/linux/drm/kernel/Makefile.linux @@ -90,9 +90,10 @@ PRGLIBS = # This may not be correct, but it is the best assumption we can make. VERSION := $(shell uname -r) -A := /usr/src/linux-$(VERSION)/include -B := /usr/src/linux/include -C := /usr/include +A := /lib/modules/$(VERSION)/build/include +B := /usr/src/linux-$(VERSION)/include +C := /usr/src/linux/include +D := /usr/include V := $(shell gcc -E -nostdinc -I$A picker.c 2>/dev/null \ | grep -s 'RELEASE = ' | cut -d' ' -f3) @@ -107,15 +108,21 @@ else V := $(shell gcc -E -nostdinc -I$C picker.c 2>/dev/null \ | grep -s 'RELEASE = ' | cut -d' ' -f3) ifeq ($(V),"$(VERSION)") - TREE := $C + TREE := $C +else + V := $(shell gcc -E -nostdinc -I$D picker.c 2>/dev/null \ + | grep -s 'RELEASE = ' | cut -d' ' -f3) +ifeq ($(V),"$(VERSION)") + TREE := $D else TREE := 0 endif endif endif +endif ifeq ($(TREE),0) -all:; @echo Error: Could not locate kernel tree in $A $B $C +all:; @echo Error: Could not locate kernel tree in $A $B $C $D else SMP := $(shell gcc -E -nostdinc -I$(TREE) picker.c 2>/dev/null \ | grep -s 'SMP = ' | cut -d' ' -f3) |