The following commit has been merged in the next branch: commit 486dc02b027ff118757c0cc530040a4e855f2e5a Author: Sven Eckelmann sven@narfation.org Date: Wed Dec 7 13:27:16 2011 +0100
batman-adv: Don't try to read commit information from target kernel
It is possible that the kernel used to build the batman-adv module also contains a .git directory. The makefile should not try to run git-describe inside this kernel to prevent that wrong version information is stored in the generated module.
Signed-off-by: Sven Eckelmann sven@narfation.org
diff --git a/Makefile b/Makefile index 99fd366..e2276be 100644 --- a/Makefile +++ b/Makefile @@ -32,8 +32,8 @@ endif export KERNELPATH RM ?= rm -f
-REVISION= $(shell if [ -d .git ]; then \ - echo $$(git describe --always --dirty --match "v*" |sed 's/^v//' 2> /dev/null || echo "[unknown]"); \ +REVISION= $(shell if [ -d "$(PWD)/.git" ]; then \ + echo $$(git --git-dir="$(PWD)/.git" describe --always --dirty --match "v*" |sed 's/^v//' 2> /dev/null || echo "[unknown]"); \ fi)
CONFIG_BATMAN_ADV=m