From: Jan Kiszka <[email protected]>

So far, passing --kerneldir=/some/kernel/build could cause broken kernel
source paths as '/build' was incorrectly cut off. Use a smarter
approach.

Signed-off-by: Jan Kiszka <[email protected]>
Signed-off-by: Marcelo Tosatti <[email protected]>

diff --git a/configure b/configure
index e01ba98..533313e 100755
--- a/configure
+++ b/configure
@@ -91,7 +91,10 @@ arch=${arch%%-*}
 
 # see if we have split build and source directories
 if [ -d "$kerneldir/include2" ]; then
-    kernelsourcedir=${kerneldir%/*}/source
+    kernelsourcedir=$kerneldir/source
+    if [ ! -L "$kernelsourcedir" ]; then
+        kernelsourcedir=${kerneldir%/build*}/source
+    fi
 fi
 
 if [ -n "$no_uname" -a "$want_module" ]; then
--
To unsubscribe from this list: send the line "unsubscribe kvm-commits" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to